Cs Project
Cs Project
# output:
Page 1 of 33
# functions with parameters but no return value:-
Output:-
Page 2 of 33
# function with parameters and return:-
#output:
Page 3 of 33
# function with return:-
Page 4 of 33
o Write a program to enter a number and find the
area of the circle.
# output:
Page 5 of 33
Positional Arguments:
For example:
1.
Page 6 of 33
Page 7 of 33
Default Arguments:
For example:
Keyword arguments:
Page 8 of 33
For example:
Page 9 of 33
o Write a program to pass string to function and
count the number of vowels in it.
# output:
Page 10 of 33
o Write a program to count how many times any
character is present in a string?
# output:
Page 11 of 33
o Write a program to pass a list to function and
double the value.
# output:
Page 12 of 33
Reading from file:
# output:
Page 13 of 33
o Write a program to read lines using readlines().
# output:
Page 14 of 33
o Write a program to count the size of files in bytes
and number of lines.
Page 15 of 33
o Write a program using “w” mode.
# output:
# text changed:
Page 16 of 33
o Write a program to write in the notepad without
overwriting the previous text.
# output:
Page 17 of 33
o Write a program to find errors in text files.
# output:
Page 18 of 33
MY SQL
o WAP to create the given table in My Sql.
Page 19 of 33
o WAP to display drinks and calories where calories
is greater than 130 from the table soft drinks .
#code:-
Page 20 of 33
o Write a SQL command for the following:
Page 21 of 33
1. To create the table bank:-
and so on………………
3. Display the details of all
Page 22 of 33
4. Display account number, customer name and
amount for those where amount is greater than
50000
Page 23 of 33
6. Display all where name starts with ‘A’
Page 24 of 33
# program to add a column in an existing table :-
Page 25 of 33
SQL Operators
● Arithmetic operator :-
Page 26 of 33
● Relational Operator :-
● Logical Operator :-
Page 27 of 33
● Special Operators :-
Page 28 of 33
Aggregate functions
# SUM()
# MIN()
# MAX()
Page 29 of 33
# COUNT()
# AVG()
# COUNT(*)
Page 30 of 33
Cartesian Product
● EQUI JOIN:-
# Inner join:-
Page 31 of 33
Page 32 of 33
Page 33 of 33