Download as pdf or txt
Download as pdf or txt
You are on page 1of 4

Finlatics: Do it yourself

Name: Durgesha Dalvi

#python program take user input of name and greet the user

name=input("Enter your name:")

print("Good Morning!", name + " ! It\'s pleasure to meet you")

# swapping of two numbers

num1_value=input("Enter the first number:")

num2_value=input("Enter the second number:")

#original value

print("num1:",num1_value)

print("num2:", num2_value)

#swapping

num1_value,num2_value=num2_value,num1_value

#after swapping

print("num1:",num1_value)

print("num2:",num2_value)
# Python promgram for radius of the circle

Radius=float(input("ENTER THE RADIUS:"))

pi=3.14

Area=pi*Radius**2

print("Area of circle is:" ,Area)

#Python program to calculate age

BIRTH_YEAR= int(input("ENTER YOUR BIRTH YEAR (YYYY):"))

import datetime

Current_Year=datetime.datetime.now().year

age= Current_Year - BIRTH_YEAR

print("Age is:",age)
#bakery owner

customer_name = input("Enter the name: ")

favorite_flavour = input("Enter flavour: ")

print("Hello,", customer_name + "! We're delighted to serve you your favorite", favorite_flavour,
"cake on your birthday. Happy Birthday.")

#simple interest

principal = float(input("Enter the principal amount: "))

rate = float(input("Enter the rate (in percentage): "))

time = float(input("Enter the Duration (years): "))

simple_interest = (principal * rate * time) / 100

print("Simple Interest is :", simple_interest)

You might also like