Rajesh SinghFeb 241 minPython Function Program without input argument and without return valueThis type of function does not have input arguments but has a value to the main program. Write a program to generate the following...

Rajesh SinghFeb 241 minPython program without input argument and with return valueThis type of function does not have input arguments but has a value to return to the main program. Write a program to calculate and print...

Rajesh SinghFeb 241 minPython Function Program with argument and without return valueThis type of function has one or more input arguments but does not have any value to return to the main program. Write a program to input...

Rajesh SinghFeb 241 minPython Function Program with input argument and with return valueThis type of function has one or more input argument and also a value to return to the main program. Write a program to input a number...

Rajesh SinghFeb 231 minPython String Programs Write a program to input a sentence and count the number of words in it. Program: s=input("Enter the sentence: ") k=0 for i in s: if...

Rajesh SinghFeb 231 minPythons Library Math Functions ProgramsWrite a program to input the value of x and calculate the result of the following equation: ex +cos x+ √ X Program: import math...

Rajesh SinghFeb 51 minPython File ProgramsWrite a program to create a text file of students to store Roll No., Name and three subject marks obtained by the students in a class of...

Rajesh SinghNov 11, 20201 minPython program to print sum of n natural numbersa=int(input("Enter a number: ")) sum = 0 while(a > 0): sum=sum+a a=a-1 print("The sum of natural numbers is",sum)

Rajesh SinghNov 10, 20201 minPython Program using function to calculate addition, substraction, multiplication and divisiondef add(a,b): print("Addition of two numbers", a+b) def sub(a,b): print("Subtraction of Two numbers",a-b) def mul(a,b):...

Rajesh SinghNov 5, 20202 minPython Programs to print pattern Number, Pyramid, Star, Diamond and Letter PatternWrite a python program for given Numbers Pattern using a for loop 1 2 2 3 3 3 4 4 4 4 5 5 5 5 5 Program: for num in range(6): for i in...

Rajesh SinghMar 31, 20201 minPython Program for Cube of a Number using FunctionsProgram: def cube(a): print("The Cube of given number", a*a*a) b = int(input(" Enter any number : ")) cube(b) Output: Please Enter any...

Rajesh SinghMar 31, 20201 minPython Program to add Two numbersProgram: num1 = int (input(" Please Enter the First Number: ")) num2 = int (input(" Please Enter the second number: ")) sum = num1+num2...

Rajesh SinghMar 31, 20201 minPython Program to find roots of a Quadratic EquationProgram: a = int(input("Enter the value of a : ")) b = int(input("Enter the value of b : ")) c = int(input("Enter the value of c : "))...

Rajesh SinghMar 31, 20201 minPython Program to Check a Number is a Perfect NumberA perfect number is a positive integer that is equal to the sum of its positive divisors, excluding the number itself. For instance, 6...

Rajesh SinghMar 31, 20201 minPython program to swap two numbersa=int(input("Enter The First Number :")) b=int(input("Enter The Second Number :")) print("Before SWAPPING a=",a," b=",b) c=a a=b b=c...

Rajesh SinghMar 29, 20201 minPython Program to Check number is Palindrome or NotA palindromic number is a number that remains the same when its digits are reversed. Like 121. Program: n=int(input("Enter number:")) a=n...

Rajesh SinghMar 29, 20201 minPython Program to Check Armstrong NumberArmstrong number is a number that is equal to the sum of cubes of its digits. For example 0, 1, 153, 370, 371 and 407 are the Armstrong...

Rajesh SinghMar 29, 20201 minPython Program to Print the Fibonacci sequencePython Program to Print the Fibonacci sequence Using While Loop num = int(input("How many terms? ")) a, b = 0, 1 i = 0 if num <= 0:...

Rajesh SinghMar 29, 20201 minWrite a Python program to print even numbers between 1 to 100.Python program to print even numbers between 1 to 100. Program: for num in range(1,100): if num%2==0: print (num) num=num+1 Output: 2 4 6...

Rajesh SinghMar 26, 20201 minWrite a Python Program to Display the multiplication Table ?Python Program to Display the multiplication Table num = int(input("Enter number: ")) for i in range(1, 11): print(num, 'x', i, '=',...