+ 1

Can you help me..please😫😩 create this codešŸ˜•

A bullet is fired vertically into the air at a speed of u m/s (meters/second). After time ts, the distance, s m, traversed by the bullet is given by the formula s = ut-4.91² By building a program code, 1. Calculate the value of s when u = 24 and t = 3 2. Calculate the value of s when u = 100 and t = 5 3. Calculate the value of s when u = 10 and t = 10 This my code ...is this right..šŸ˜ŸšŸ˜• https://code.sololearn.com/cEtDgAbD0ZY5/?ref=app

25th Aug 2021, 9:44 AM
NURUL AIN SYAFIQAH BINTI MUHAMMAD NAZIR
NURUL AIN SYAFIQAH BINTI MUHAMMAD NAZIR - avatar
3 Answers
+ 2
Ouhh ... thank you for your explanation šŸ˜„šŸ¤—šŸ‘
25th Aug 2021, 10:12 AM
NURUL AIN SYAFIQAH BINTI MUHAMMAD NAZIR
NURUL AIN SYAFIQAH BINTI MUHAMMAD NAZIR - avatar
+ 1
Your Mistakes : 1. 4.91^2 use ** operator to calculate powers 4.91**2 Note Double stars (**) are exponentiation. so it means 4.91 to the power 2 print(4.91**2) output: 24.1081 print(4.91*4.91) output: 24.1081 print(4.91^2) output: unsupported operand type(s) for ^: 'float' and 'int'
25th Aug 2021, 9:59 AM
Pariket Thakur
Pariket Thakur - avatar
+ 1
Hi NURUL! Your concept and syntax are fine. But the problem is that "^" is known as bitwise xor operator whereas "**" sign is used for exponentiation. ^ can't be applied to floats
25th Aug 2021, 10:03 AM
Python Learner
Python Learner - avatar