How to start: Take two list from from the user. Then , merge two list and show the result. Source code: a=c=n1=int(input(“Enter number of elements:”)) for i in range(1,n1+1): b=int(input(“Enter element:”)) a.append(b)n2=int(input(“Enter number of elements:”)) for i in range(1,n2+1): d=int(input(“Enter element:”)) c.append(d) n=a+c new.sort()print(“Sorted list is:”,n) Output: Explanation: User input Continue Reading
How to do? Take input number(to form table) from the user . Process to make formation of table through lopping Source code: n=int(input(“Enter the no.to generate mul table:”))for i in range(1,12): print(n,”x”,i,”=”,n*i) Explanation: program ask user to input number to generate multiplication table. Program starts looping to generate table. Output:
firstly , we need to know about bubble short . what is happening during bubble shorting. >>> In Bubble short elements of one position is compare to the next position and arrange the elements whatever we want. Here is the source code example for bubble short. Output: Explanation: 1.firstly , Continue Reading
There are many ways to short the given elements in c programming . let us look different process of shorting of elements in c programming one by one. Bubble short. selection short. merge short.
we can create simple key press event using python by binding the keys of the keyboard by using canvas.bind_allfunction .example: canvas.bind_all(‘<KeyPress-w>’,self.up) Here is the simple example of key bind function: from tkinter import * import time import random win=Tk() win.title(“game”) canvas=Canvas(win,width=500,height=500) canvas.pack() t=(“red”,”green”,”blue”,”grey”,”pink”,”black”,”yellow”,”orange”) class Bind(): def __init__(self,color,size): Continue Reading
Julia is the dyamic programming language is one of the popular language , in case the matter is come about the scientific computing, no other language can beat julia.It’s a free and open source programming language which is very much capable of providing high-performance(high speed) comparing to other languages like Continue Reading
To count the number of vowels in a string we need to do following steps. reading the string from the user. create a set of string containing vowels compare the given string to the set of vowels. count the number of vowels if match found. print the result. For that Continue Reading
To create a bouncing ball animation .firstly we need to import tkinter and create a canvas . The source code is given below: correct the spaces in the program To learn more click here.
To find largest and smallest number in a list using python programming . firstly, we need to input elements in a list and print the output which one is largest and which one smallest . The code is given below: n=int(input(“Enter the number of elements to be in the list:”)) Continue Reading
Before know the source code we need to understand the concept about primat number . what is prime number? >>The number which is only divisible by 1 or itself. or >>The number which do not come in others numbers multiplication table . To check the given number is prime ,firstly Continue Reading