Onlinehomeworkandassignmentskvpt.files.wordpress.com



COMPUTER SCIENCE LAB PRACTICALS 2019-20CLASS XIWrite a program to find sum of 2 numbers.Write a program to find simple interest.Write a program to find area and perimeter of a rectangle.Write a program to print first five multiples of a number.Write a program to read the numbers in three variables and swap 1st two variables with the sum of first and second, second and third numbers respectively.Write a Python program to check whether a given character is a digit or alphabet or any other character.Write a Python program to check whether the given year is leap year or not.Write a program to input two numbers and find the largest number.Write a Python program to input a digit and display it in words.Write a Python program to print Fibonacci series of first 10 elements. Write a Python program to read an integer>1000 and reverse the number.Write a Python program to generate divisors of a number.Write a Python program to input two numbers and print their lcm and GCD.Write a Python program to print the sum of natural numbers between 1 and 25.Write a program to print the numbers within a range in reverse order. The numbers must be separated using coma.Write a menu driven program to input a number and perform the following operations:Check the number is even or notFind the factorial of the number. Write a program to display numbers upto n. Also display the sum of even numbers and odd numbers. Write a menu driven program to input a number and perform the following operations:Check whether number is palindrome or notSum of digits of the number Write a Python program to print the following pattern:12 23 3 3Write a program to print the largest and minimum element in list and its index.Write a program to input a list from user. Create two lists, unique and duplicate list. Write a program to create a list and perform the following:Search an element in listCount the frequency of an element in list without using count() function.Mean of elements in the list. Write a program that takes a list l , adds 5 in all odd values and 10 in all the even values of the list. Also display the list.Write a program to find the largest element in the tuple.Write a program to remove an element from the tuple.Write a program to print the count of elements in the list. Write a program to store phone numbers and name into dictionary. Search for a phone number in dictionary. If the name is not found in the dictionary display appropriate message. Write a program that uses a dictionary phonebook that contains five username and password. Also, check the name which is entered by the user is present in the dictionary, if it is not present , print “invalid user”. If user is present in dictionary, then ask the user to enter password, if it is correct, then print you have logged in else print “INCORRECT PASSWORD”.Add a new username and password, input from user.Delete an username as input from user, if the username exists, delete the particular detail otherwise display appropriate messagecreate a dictionary from a string with frequency of letters.Write a Python script to sort (ascending and descending) a dictionary by value. ?Write a Python program to sort a dictionary by key.? Write a Python program to get the maximum and minimum value in a dictionary. Write a Python program to sort a list alphabetically in a dictionary. Write a Python program to count the number of characters (character frequency) in a string.?Sample String : 'Expected Result : {'o': 3, 'g': 2, '.': 1, 'e': 1, 'l': 1, 'm': 1, 'c': 1} Write a Python program to add 'ing' at the end of a given string (length should be at least 3). If the given string already ends with 'ing' then add 'ly' instead. If the string length of the given string is less than 3, leave it unchanged. Sample String : 'abc'Expected Result : 'abcing'Sample String : 'string'Expected Result : 'stringly' Write a Python program to find the first appearance of the substring 'not' and 'poor' from a given string, if 'not' follows the 'poor', replace the whole 'not'...'poor' substring with 'good'. Return the resulting string.Sample String : 'The lyrics is not that poor!''The lyrics is poor!'Expected Result : 'The lyrics is good!''The lyrics is poor!'Write a Python function that takes a list of words and returns the length of the longest one along with the words.Write a Python program to count repeated characters in a string.? Sample string: 'thequickbrownfoxjumpsoverthelazydog'Expected output :o 4e 3u 2h 2r 2t 2 Consider the table EXAM given below. Write commands in MySql for(i) to (iv) and output for (v) to (vii) Table: EXAM To list the names of those students, who have obtained Division as FIRST in the ascending order of NAME. To display a report listing NAME, SUBJECT and Annual stipend received assuming that the stipend column has monthly stipend. To count the number of students, who have either accounts or informatics as subject. To insert a new row in the table EXAM: 6,”Mohan”,500,”English”,73,”Second” SELECT AVG(Stipend) FROM EXAM WHERE DIVISION=”THIRD” SELECT COUNT(DISTINCT Subject) FROM EXAM; (vii) SELECT MIN(Average) FROM EXAM WHERE Subject=”English”; ................
................

In order to avoid copyright disputes, this page is only a partial summary.

Google Online Preview   Download