Back

Python exercise to convert km into m and cm

Created 1 year ago
441 Views
3 Comments
RohitK
@RohitK
RohitK
@RohitKProfile is locked. Login

Please help me in understanding where am I going wrong.

So this is the problem statement.

You are given a number A in Kilometers. Convert this into B: Meters and C: Centi-Metres.

Input Description:
A number "A" representing some distance in kilometer is provided to you as the input.

Output Description:
Convert and print this value in meters and centimeters.

Sample Input : 2

Sample Output : 2000 200000

For this, pasting down below my code line:

A = int(input())
B = A*1000
C= A*10000
print (B)
print (C)
Comments (3)
Please login to comment.