Вы находитесь на странице: 1из 8

LIST OF PROGRAMS

PRACTICAL FILE 2019-20


SUBJECT: INFORMATICS PRACTICES OLD(265)
CLASS: XII

Java GUI Programming


1. Create a Java desktop application that accepts two numbers and calculates the sum, subtraction,
multiplication, division and modulus. Also write the code for clear button to clear the data of all the text
fields and EXIT button to close the application.

2. Create a GUI application to display the factorial of a number entered by the user in form of label.

3. Create a GUI application to find out the greatest number from three numbers entered by the user in the
given text fields.
4. Create a GUI application to display the compound interest of every year in the given text area where
principle, rate and time are entered by the user.

5. Create a GUI application to retrieves the password from the Password field and display it in form of
label.

6. Create a GUI application to display a series of even numbers in given text area upto nth term entered by
the user.
7. Create an application that prints the week day name depending upon weekday number entered by the
user. (Example: No. 1 for Monday, 2 for Tuesday and so on.)

8. Create a GUI application to compute the sum of digits for given number and display it in the given text
field. Also write the code for Exit button to close the application.

9. Create a GUI application to perform the following calculations:


 Enter number of units purchased, rate per unit and discount percentage on the purchased items.
 Calculate the total bill amount, discount given to customer and net amount to be paid.

10. Create an application to display whether a number entered by the user is even or odd.
(i) Enter any number in the given Textfield.
(ii) Then click on Check button, if number entered by the user is even then a Message Box
should be displayed with a message “Even Number” and if number entered by the user is
odd then a Message Box should be displayed with a message “Odd Number”.
11. Create a GUI application to display the sum of the following series upto n terms where the no. of terms
is entered by the user
If user enters 5, the sum of the series is 12+22+32+42+52 i.e. 55

12. Create a GUI Java Application which add and remove the employees' names in the combo box on the
bases of the given buttons:
(i) Write the code for ADD button to add the employee name in the combo box typed by the
user in the given text field
(ii) Write the code for REMOVE button to remove a selected name from the combo box.
(iii) Write the code for CLEAR button to clear the employee name from the text field.
(iv)
13 Create a GUI application to calculate the salary of the employee according to the given criteria:

Employee type Basic salary Deduction (% of basic salary)


Clerical 12500 12
Technician 14500 12
Labourer 10500 7
If any employee has an experience of more than 10 years he/she should be paid Rs 3000/- additionally.
Write the coding of CALCULATE button to calculate DEDUCTION and NET SALARY of an employee.

14. Create a GUI Java application to calculate the discount and Net amount to be paid according to the
discount percentage selected from the list of discounts as shown in the given form.

15. Ruchika is a programmer at Alpha Builders. To calculate wages to be paid to labourers she has
developed the following GUI in Netbeans. Male and Female labourers are paid at the rate of Rs. 140/-
per day and Rs. 160/- per day respectively. Skilled labourers are paid an additional rate of Rs. 50/- per
day. Also write the code for clear button.
MySQL
1. Write the SQL commands for the question from (i) to (xviii) on the basis of table TEACHER given
below:
Table: TEACHER
TNo Tname Gender Age Department Salary DOJ Phone
101 Ashok Kumar M 28 English 15000 2010-10-13 234354
102 Rakesh Sharma M 32 Mathematics 25000 2008-08-23 NULL
103 Richa Saini F 27 Computer 22000 2014-07-15 224455
104 Amit Gupta M 35 Science 17000 2010-09-05 254678
105 Sandeep Goyal M 42 Computer 19000 2005-12-27 653423
106 Sangeeta F 33 English 14000 2008-11-17 NULL
107 Jyoti Sharma F 29 Hindi 12000 2012-05-13 244244
108 Manoj Kumar M 40 Science 21000 2005-03-01 NULL
109 Rajendra Kapoor M 36 Art 16000 2004-04-25 233456
111 Vinay Kumar M 32 English 18000 2011-03-10 231234
i. To display the detail of teachers in descending order of their salary.
ii. To display the teachers’ number, teachers’ name, gender and department of all teachers in ascending
order of their date of joining.
iii. To display the teacher’s number and teacher’s name of all the teachers whose age is more than 35.
iv. To display the details of all the male staff of English department.
v. To display the name and department of the teachers who joined the school in 2004 and 2005.
vi. To display the detail of the teachers whose age is between 30 and 40 years.
vii. To display the teachers’ number, teachers’ name of English, Hindi and Science departments.
viii. To display the name and department of those teachers whose phone number is not available.
ix. To display the detail of the teachers whose name starts with alphabet ‘R’.
x. To display teachers name, age, department and salary of the teachers whose name ends with ‘a’.
xi. To display the teachers name, gender, department and salary of the teachers who belongs to the
departments Art and Computer.
xii. To display the department name and average salary of each department.
xiii. To display the maximum and minimum salary of each department along with department name.
xiv. To increase the salary by 2000 for the teachers of computer department.
xv. To remove the detail of the teacher whose teacher number is 108.
xvi. To add one more column Address of type varchar (30) in the table teacher.
xvii. To remove the column phone from the table.
xviii. To remove the table teacher from the database.
2. Consider the tables given below:
Table: SALESPERSON
SalespersonId Name Age Salary
1 Ajay 55 70000
2 Sunil 34 44000
5 Satvik 40 40000
7 Ashok 42 52000

Table: ORDERS
OrderId SalespersonId Amount
O111 2 54000
O213 7 18000
O221 1 46000
O245 5 24000
With reference to the above given tables, write the commands in SQL for (i) and (ii).
(i) To display SalespersonId, Names, age and OrderId of those salesperson whose names starts with
‘A’.
(ii) To display SalespersonId, Names, OrderId and sales amount of those salespersons whose sales
amount is between 15000 and 30000.
HTML
1. Write the HTML code to design the following web page using list tags.

2. Write the HTML code to design the following web page using form tags.
3. Write the HTML code to design the following web page using form tags.

Вам также может понравиться