Skip to content

Latest commit

 

History

History
50 lines (34 loc) · 958 Bytes

File metadata and controls

50 lines (34 loc) · 958 Bytes

MSNT 657: Python Fundamentals

Student Name: Christopher Smith

Professor: Dr. Vandenbrink

# Any python interpreter can be used as a calculator:
3 + 5 * 4

# Lets save a value to a variable
weight kg = 60
print(weight_kg)

# Weight0 = valud
# Oweight = invalid
# weight and Weight are different

# Types of data
# There are three common types of data
# Integer numbers
# floating point numbers
# Strings

weight_kg = 60.3

# Use variables in python
weight_lb = 2.2 * weight_kg

print(weight_lb)

# Let's add a prefix to our patient ID
patient_id = 'inflam_' + patient_id

print(patient_id)

# Let's combine print statements
print(patient_id + 'weight in kilograms:' + weight_kg)

# We can call a function inside another function
print(type(60.3))

print(type(patient_id))

# We can also do calculations inside the print function
print('weight in lbs:', 2.2 * weight_kg)

weight_kg = 65.0
print('weight in kilograms is now:', weight_kg)