Ethio CodeToolkit
Open in Telegram
Your go-to for Ethiopian coding contests. Find the latest contests, resources, and community support. Join us to level up your coding skills!
Show more1 240
Subscribers
No data24 hours
-27 days
-2130 days
Posts Archive
1 240
Benefits of joining A2SV
📝 Free Education: A2SV provides free in-person and remote education programs covering lectures, problem-solving, mock interviews, communication skills, and project development. This empowers aspiring software developers with practical skills for success in the tech industry.
👩🏫 Mentorship and Guidance: A2SV connects students with experienced mentors who can provide guidance, support, and feedback throughout their learning journey.
📞 Networking Opportunities: Joining A2SV allows you to connect with other talented individuals, industry professionals, and potential employers.
🚀 Project Development: A2SV offers opportunities to work on real-world projects, which helps you gain practical experience and build your portfolio.
🤑 Placement Assistance: A2SV assists students in finding internships and jobs at top tech companies.
1 240
Requirements to join A2SV in person education
💎 be familiar at least in one programming language
💎 Solve total 80 problems in leetcode and codeforce
💎 Being Student at AU,AASTU or ASTU regardless of batch or department
1 240
1588 Sum of all add length subarrays solution
class Solution(object):
def sumOddLengthSubarrays(self, arr):
"""
:type arr: List[int]
:rtype: int
"""
nums =arr
def prefixSum(nums):
ans = [0]
for i in nums:
l = ans[-1]
ans.append(l+i)
return ans
ans = prefixSum(nums)
summ = 0
i = 1
end = 1
while i
1 240
1004 max consecutive Ones III solution
class Solution:
def longestOnes(self, nums: List[int], k: int) -> int:
start,end=0,0
window = 1
max = window
while start0:
k-=1
while end0:
if nums[end+1] != 1:
k-=1
end+=1
window+=1
else:
if nums[start]==0:
k+=1
start+=1
window-=1
if max
1 240
724 find pivot index solution
class Solution:
def pivotIndex(self, nums: List[int]) -> int:
pre_sum = [0]
for i in nums:
pre_sum.append(pre_sum[-1]+i)
for j in range(len(nums)):
total = pre_sum[-1]
left = pre_sum[j]
right = total-left-nums[j]
if left == right:
return j
return -1
1 240
303 Range sum query Solution
class NumArray:
def init(self, nums: List[int]):
self.nums = nums
self.pre_sum = [0]
for i in nums:
self.pre_sum.append(self.pre_sum[-1]+i)
def sumRange(self, left: int, right: int) -> int:
rigth_sum = self.pre_sum[right+1]
left_sum = self.pre_sum[left]
return rigth_sum-left_sum
# Your NumArray object will be instantiated and called as such:
# obj = NumArray(nums)
# param_1 = obj.sumRange(left,right)
