# Rounding a number in Python
# Using round() function with default precision
num1 = 3.14159
rounded_num1 = round(num1)
print(rounded_num1) # Output: 3
# Using round() function with custom precision
num2 = 5.6789
rounded_num2 = round(num2, 2) # Round to 2 decimal places
print(rounded_num2) # Output: 5.68
# For rounding to a specific decimal place without using round()
num3 = 7.54321
rounded_num3 = int(num3 * 10) / 10 # Round to 1 decimal place (by multiplying and converting to int)
print(rounded_num3) # Output: 7.5