Question: Calculate initial velocity Problem Statement The first equation of motion is v = u + a * * t where, v: final velocity

Calculate initial velocity
Problem Statement
The first equation of motion is "v=u+a**t" where,
v: final velocity in meters/second
u: initial velocity in meters/second
a: acceleration in meters/second ?2
t: time interval in second
You are given the final velocity, acceleration, and time interval. Find the initial velocity.
Input Format
The input consists of a single line:
The line contains three integers v,a, and t respectively.
Input will be read from the STDIN by the candidate
Output Format:
Print the initial velocity i.e.u.
The output will be matched to the candidate's output printed on the STDOUT
Constraints:
1v106
1a103
1t103
Example:
Input:
111
Output
0
Explanation:
By first equation of motion we have u=v-a**t, Now v=a=t=1 hence u=1-1**1=0.
Sample input
522
Sample Output
1
Instructions :
Program should take input from standard input and print output to standard output.
Your code is judged by an automated system, do not write any additional welcome/greeting messas
"Save and Test" only checks for basic test cases, more rigorous cases will be used to judge your co
Additional score will be given for writing optimized code both in terms of memory and execution tim
Now let's start coding :
Language: Java 17.0
1
import
java.io.*;
 Calculate initial velocity Problem Statement The first equation of motion is

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!