Skip to content

Day 1 Begginer Helpppp #3965

@ashercarson

Description

@ashercarson
  1. Is here right way that I can ask a question?

  2. weight = int(input('Weight: '))
  3. unit = input('(L)bs or (K)g: ')
  4. if unit.upper() == 'L':
  5. converted = weight * 0.45
    
  6. print(f"You are {converted} kilos")
    
  7. elif unit.upper() == 'K':
  8. converted = weight / 0.45
    
  9. print(f"You are {converted} pounds")
    
  10. else:
  11. print("Please Enter the letters l or k")
    
  12. #I wanna add more optional letters ( LBS, KG ) on 4, 7 lines
  13. and when I put (or ,) by the next of 'L' and 'K'
  14. it doesn't work properly.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions