Search This Blog
Wednesday, September 21, 2022
Tuesday, September 13, 2022
Technical training work:
1.write a C program to print the numbers from n to 0 using for loop.
2.write a C program to print the numbers from n to 0 using while loop.
3.write a C program to print sum of numbers in the given range.
4.write a C program to print even numbers in the given range without using == operator.
5.write a C program to print odd numbers in the given range without using != operator.
6.write a C program to print mathematical table of any given number upto some range.
7.write a C program to print sum of digits in the given number.
8.write a C program to print all the even digits in the given number.
9.write a C program to print sum of the even digits in the given number.
10.write a C program to print difference between sum of even digits and sum of odd digits in the given number.
Monday, August 8, 2022
Thursday, June 2, 2022
Thursday, May 5, 2022
python
def convert(s):
f = float(s)
c = (f - 32) * 5/9
return c
print(convert(78)Height=float(input("Enter your height in centimeters: "))
Weight=float(input("Enter your Weight in Kg: "))
Height = Height/100
BMI=Weight/(Height*Height)
print("your Body Mass Index is: ",BMI)
if(BMI>0):
if(BMI<=16):
print("you are severely underweight")
elif(BMI<=18.5):
print("you are underweight")
elif(BMI<=25):
print("you are Healthy")
elif(BMI<=30):
print("you are overweight")
else: print("you are severely overweight")
else:("enter valid details")Thursday, April 7, 2022
dice rolling
import random
while True:print(''' 1. roll the dice 2. exit ''')
user = int(input("what you want to do\n"))
if user==1:
number = random.randint(1,6)
print(number)
else:
break
Sunday, January 9, 2022
PL/SQL program
declare
name employee.fname%type;
sa employee.salary%type;
cursor c2 is select fname,salary from employee;
BEGIN
open c2;
update employee set salary=salary+(salary*0.2);
loop
fetch c2 into name,sa;
exit when c2%NOTFOUND;
DBMS_OUTPUT.PUT_LINE(name||'having updated salary is ' ||sa);
end loop;
END;
declare
emp employee.fname%type;
ss employee.ssn%type:=&ssn;
begin
select fname into emp from employee where ssn=ss;
if sql%notfound then
DBMS_OUTPUT.PUT_LINE('no records found');
else
DBMS_OUTPUT.PUT_LINE('found');
end if;
end;
/
CREATE [OR REPLACE] FUNCTION function_name
[(parameter_name [IN | OUT | IN OUT] type [, ...])]
RETURN return_datatype
{IS | AS}
BEGIN
< function_body >
END [function_name];
CREATE OR REPLACE FUNCTION sailorscount
RETURN number IS
total number(2) := 0;
BEGIN
SELECT count(*) into total
FROM sailors;
RETURN total;
END;
/
CREATE OR REPLACE FUNCTION findMax(x IN number, y IN number)
RETURN number
IS
z number;
BEGIN
IF x > y THEN
z:= x;
ELSE
Z:= y;
END IF;
RETURN z;
END;
DECLARE
a number;
b number;
c number;
BEGIN
a:= &a;
b:= &b;
c := findMax(a, b);
dbms_output.put_line(' Maximum of (a,b): ' || c);
END;
/
DECLARE
num number;
factorial number;
FUNCTION fact(x number)
RETURN number
IS
f number;
BEGIN
IF x=0 THEN
f := 1;
ELSE
f := x * fact(x-1);
END IF;
RETURN f;
END;
BEGIN
num:= #
factorial := fact(num);
dbms_output.put_line(' Factorial '|| num || ' is ' || factorial);
END;
/
create or replace PROCEDURE findMin(x IN number, y IN number, z OUT number) IS
BEGIN
IF x < y THEN
z:= x;
ELSE
z:= y;
END IF;
END;
DECLARE
a number;
b number;
c number;
BEGIN
a:= 23;
b:= 45;
findMin(a, b, c);
dbms_output.put_line(' Minimum of (23, 45) : ' || c);
END;
/
DECLARE
a number;
PROCEDURE squareNum(x IN OUT number) IS
BEGIN
x := x * x;
END;
BEGIN
a:= 23;
squareNum(a);
dbms_output.put_line(' Square of (23): ' || a);
END;
/
CREATE [OR REPLACE] PROCEDURE procedure_name
[(parameter_name [IN | OUT | IN OUT] type [, ...])]
{IS | AS}
BEGIN
< procedure_body >
END procedure_name;
CREATE OR REPLACE PROCEDURE greetings
AS
BEGIN
dbms_output.put_line('Hello World!');
END;
/
EXECUTE greetings;
Drop procedure procedurename;
The CASE statement goes through conditions and returns a value when the first condition is met (like an if-then-else statement). So, once a condition is true, it will stop reading and return the result. If no conditions are true, it returns the value in the ELSE clause.
If there is no ELSE part and no conditions are true, it returns NULL.
CASE Syntax
CASE
WHEN condition1 THEN result1
WHEN condition2 THEN result2
WHEN conditionN THEN resultN
ELSE result
END;
DECLARE
grade char(1) := 'A';
BEGIN
CASE grade
when 'A' then dbms_output.put_line('Excellent');
when 'B' then dbms_output.put_line('Very good');
when 'C' then dbms_output.put_line('Well done');
when 'D' then dbms_output.put_line('You passed');
when 'F' then dbms_output.put_line('Better try again');
else dbms_output.put_line('No such grade');
END CASE;
END;
/
DECLARE
grade char(1) := 'B';
BEGIN
case
when grade = 'A' then dbms_output.put_line('Excellent');
when grade = 'B' then dbms_output.put_line('Very good');
when grade = 'C' then dbms_output.put_line('Well done');
when grade = 'D' then dbms_output.put_line('You passed');
when grade = 'F' then dbms_output.put_line('Better try again');
else dbms_output.put_line('No such grade');
end case;
END;
/
Write a PL/SQL program for generating Fibonacci series
declare
a number;
b number;
c number;
n number;
i number;
begin
n:=&n;
a:=0;
b:=1;
dbms_output.put_line(a);
dbms_output.put_line(b);
for i in 1..n-2
loop
c:=a+b;
dbms_output.put_line(c);
a:=b;
b:=c;
end loop;
end;
Thursday, November 25, 2021
PYTHON BY DURGA SOFT
STRINGS - TUPLES - SETS - DICTIONARIES
Cheat Sheet for Regular Expression ( Courtesy: www.dataquest.io )
Wednesday, November 24, 2021
Wednesday, November 10, 2021
R20 DBMS course Content
click here to download Database System Concepts 7th edition
click here to download Database Systems - Design, Implementation, and Management (9th Edition)
SEM papers:
R17-DBMS SUPPLY - EXAM DATE 25-10-2021
R17 -DBMS REGULAR - 09-04-2021
UNIT- I
Introduction: An overview of Database Management System
Data Modelling using the Entity Relationship Model
Database Systems - Design, Implementation, and Management (9th Edition)-34-58
Database-System-Concepts-7th-Edition-30-63
ASSIGNMENT (LAST DATE FOR SUBMISSION IS (02-12-2021)
University Database Case Study for ER diagram:
Movie Data Base Case Study for ER diagram
UNIT- II
Relational Data Model and Language
DESCRIPTIVE QUESTIONS -II
QUIZ QUESTIONS - II
UNIT- III
Database Systems - Design, Implementation, and Management (9th Edition)[204-246]
Transaction Management and Concurrency Control
DESCRIPTIVE QUESTIONS -III
QUIZ QUESTIONS - III
UNIT- IV
TRANSACTION CONFLICTS/ANOMALIES ppt
Database Systems - Design, Implementation, and Management (9th Edition)-444-474
DESCRIPTIVE QUESTIONS -IV
QUIZ QUESTIONS - IV
UNIT- V
Hashing notes
DESCRIPTIVE QUESTIONS -V
QUIZ QUESTIONS - V
Friday, October 8, 2021
Monday, September 6, 2021
Friday, April 16, 2021
Wednesday, April 14, 2021
Tuesday, March 2, 2021
Thursday, February 25, 2021
Wednesday, February 17, 2021
Thursday, February 4, 2021
Tuesday, February 2, 2021
Sunday, January 31, 2021
Sunday, January 10, 2021
Data Base Management System
sailors ,Boats & reserves
UNIT-1:
Unit -1 Data(Database Systems - Design, Implementation, and Management (9th Edition)-34-58)
UNIT-2:
UNIT-3:
UNIT-4:
Transaction Management material
Transaction management & concurrency control text Book
Rules for 4th Normal Form & lossless join
UNIT-5:
Sunday, February 23, 2020
Few lucky attendees at the Fair will be given a pack of candies as a lucky gift and the show coordinator has assigned you the task for choosing the number of attendees who will receive the pack of candies. There are 'N' candies available and you need to decide how many candies to place in each pack. Each pack must contain the same number of candies. You should choose an integer A between 1 and N, inclusive, and place exactly A candies into each pack. You should make as many packs as possible but since you enjoy eating candies very much, you eat the remaining candies.
Write a program that will calculate the pack size(A) so that you can eat as many candies as possible. If multiple pack size will result in the same number of leftover candies, then print the largest pack size.
Input Format:
The first and only line of input contains an integer N.
Output Format:
Output a single line that gives the pack size that will maximize the number of leftover candies.
Refer sample input and output for formatting specifications.
Sample Input 1:
2
Sample Output 1:
2
Explanation:
There will be no leftover candies regardless of the size of the pack you choose. So you choose the largest possible pack size 2.
Sample Input 2:
5
Sample Output 2:
3
Explanation:
There will be 2 leftover candies, if you choose 3 as the pack size.
Consider a currency system in which there are notes of seven denominations, namely, Rs. 1, Rs. 2, Rs. 5, Rs. 10, Rs. 50, Rs. 100. If the change given to Pranav Rs. N is input, write a program to computer smallest number of notes that will combine to give Rs. N.
Note:
Refer to problem specifications.
Input Format:
First line of the input is an integer N, the change to be given to Pranav.
Output Format:
Output should display the the smallest number of notes that will combine to give N.
Refer sample input and output for formatting specifications.
Sample Input 1:
1200
Sample Output1:
12
Sample Input 2:
242
Sample Output2:
7
Problem Requirements:
C
| Keyword | Min Count | Max Count |
| do | 0 | 0 |
| Keyword | Min Count | Max Count |
| while .... | 0 | 0 |
Help the kids by writing a program to find the area of the largest possible square that can be formed, given the side of a square tile (in cms) and the number of square tiles available.
Input Format:
First line of the input is an integer that corresponds to the side of a square tile (in cms).
Second line of the input is an integer that corresponds to the number of square tiles available.
Output Format:
Output should display the area of the largest possible square that can be formed (in square cms) with the available tiles.
Refer sample input and output for formatting specifications.
[All text in bold corresponds to input and rest corresponds to output.]
Sample Input and Output :
Enter the side in cm of a square tile
5
Enter the number of square tiles available
8
Area of the largest possible square is 100sqcm
Sunday, February 16, 2020
Thursday, February 6, 2020
Thursday, December 5, 2019
link
https://wayground.com/join?gc=966822
-
https://meet.google.com/qjv-erbu-ewf Lab Syllabus Theory Syllabus WEEK1 WEEK2 ----> Insertion WEEK3 WEEK4 WEEK5 WEEK6 -----> Solutions...
-
Lucky Gifts "Planet Kids Entertainment Fair" is back to delight kids and parents. The Fair will have non-stop entertainment w...
-
Classroom link: https://classroom.google.com/c/ODc0OTQxMjY1MjA5?cjc=rq67ikqo class code: rq67ikqo