How was your CodeVita 2019?

Luckily i didn’t have this problem in my set. Do you know about the exact constraints?

1 Like

Unfortunately I don’t remember the constraints now but I guess anything better than Brute Force should work, If i get the constraints I will let you know.

Is there a way to view my submissions now? I have solved Codevita and been called for an interview. I want to review my solutions. Where can I do that now?

Can anyone know about the codevita Zone 1 2019 quetions

Kindly send pdf bro…

Brother can you provide me “uncertain steps” question of codevita. I lost it plz asap provide me if someone has. I will be having interview tomorrow

1 Like
Uncertain Steps

Problem Description
Codu is trying to go down stairs from his building to ground floor.
He can go 3 ways:

  1. Walk 1 step at a time.
  2. Extend his legs and go 2 steps at a time.
  3. Jump down 3 steps at a time.
    Given n steps, calculate the number of possible ways to reach the ground floor, provided he can jump 3 steps at most once during this process.
    That is, he can jump down 3 steps only once, but at any time, if he wishes, while walking down the stairs.
    Constraints
    1 <= N <= 1000000.
    Input Format
    Single Integer denoting the number of Steps, N.
    Output
    Number of ways to reach ground floor.
    As the number can be huge, give output modulo 1000000007.
    Test Case
    Explanation
    Example 1
    Input
    4
    Output
    7
    Explanation
    1, 1, 1, 1
    1, 2, 1
    1, 1, 2
    1, 3
    2, 1, 1
    2, 2
    3, 1
    Number of ways = 7.

Can you explain me the logic to solve this question? My mail id is aadityakumarrai445@gmail.com
Kindly drop your number if possible plzz, I am not getting it now

Your rank is 118. Ping me so we can discuss cp strategies.

Login to tcs website. you’ll find it there.

Ya sure … I am in CS4 (both ggct && ggits combined) or CS1(in ggct) 3rd sem(2nd year)

I am in GGITS 3rd sem CS1.

oh i’ve seen ur insta … fitness freak! :slight_smile:

1 Like

I have send connect request via linkedin.

Thanks bro. Congrats for 4 stars.

oh that will again be 3 stars in next challange :sweat_smile:

:grinning:Hope for good. Well I want to know do you have any interest in coding clubs of our college eg Let’s Code It.

I just received email from codechef that I have won 100% scholarship for exam. Are you going to bhopal for exam??:face_with_raised_eyebrow:

1 Like

yeah but Saturdays are for rest … and they want us to come on saturdays

2 Likes

I tried to solve the Bit Score in python, but faced a problem
i am getting presentation error during public test cases and wrong answer while private test cases can u resolve my problem
i=int(input())
l=input().split()
g=[]
for j in l:
g+=[[int(min(j)),int(max(j))]]
d=[]
for j in g :
d+=[j[1]*11+j[0]*7]
k=[]
for j in d :
g=[]
j=int(j)
for h in range(2):
r=j%10
j=j//10
g+=[r]
g.reverse()
k+=[g]
def temp(k):
pair=0
for j in range(len(k)):
for f in range(len(k)):
if j<=f:
continue
elif k[j][0]==k[f][0]:
pair+=1
break
return pair
g=list(filter(lambda x: k.index(x)%2==0,k))
w=list(filter(lambda x: k.index(x)%2!=0,k))
r=temp(g)+temp(w)
print(str®)