Simple Python programs

Write a Python program to input 2 Integer number and find its Sum:

num1=int(input("Enter First Number "))
num2=int(input("Enter Second Number "))
ans=num1+num2
print("Sum is : ",ans)


Write a Python program to input 2 Float Number and Find its multiplication:

num1=float(input("Enter First Number "))
num2=float(input("Enter Second Number "))
ans=num1*num2
print("Product (multiplication ) is : ",ans)


Qus. 1 : Which of the following is a feature of DocString?

  1. Provide a convenient way of associating documentation with Python modules, functions, classes, and methods.
  2. All functions should have a docstring.
  3. Docstrings can be accessed by the ___doc_attribute on objects.
  4. All of the mentioned.

Programs

python program to input a welcome message and print it

View Solution


python program to print number of seconds in year

View Solution


Python program to calculate GST Goods and Service Tax

View Solution


python program to find the ASCII Value of entered character

View Solution


python program that display a joke but display the punch line only when the user presses enter key

View Solution


python program to generate the following output 5 10 9

View Solution


python program to print 5@10@9

View Solution


CCC Online Test Python Programming Tutorials Best Computer Training Institute in Prayagraj (Allahabad) Online Exam Quiz O Level NIELIT Study material and Quiz Bank SSC Railway TET UPTET Question Bank career counselling in allahabad Best Website and Software Company in Allahabad Website development Company in Allahabad