Uphill shooting

Back to General discussions forum

pr_durgam.17je003008     2020-05-01 07:58:39

import math MainCount=3 while MainCount>0: YCoordy=input().split() NCount=0 for elements in YCoordy: YCoordy[NCount]=int(YCoordy[NCount]) NCount+=1 SubCount=3 while SubCount>0: Velocity,Angle=map(float,input().split()) X=0 Y=0 SubSubCount=0 while (4((YCoordy[SubSubCount])))<=Y or SubSubCount==0: X+=1 Y=(X(math.tan((Angle(math.pi))/180)))-(0.59.81((X/(Velocity(math.cos((Angle*(math.pi))/180))))**2)) if int(X)>=1 and int(X)%4==0: SubSubCount+=1 print(X) print(Y) print(4*(YCoordy[SubSubCount])) print(' ') SubCount-=1 MainCount-=1 this code isnt working good , i think there is something wrong in compiling

The Black Knight     2020-05-01 13:21:02

It's hard to tell what you're code it trying to do as the forum's formatted it as one big long bit of text and python's very reliant on formatting. Apparently if you indent the code in the post with four spaces, it will be processed as a code block.

At a glance, you might have missed an asterisk here "0.59.81". Hard to say though.

Please login and solve 5 problems to be able to post at forum