Get the step-by-step solution for this question inside the Vidyadip app.
Get the answer in the appGenerate a complete, print-ready paper with questions like this in minutes — across 16+ boards, with answer keys.
Write a program to create the list and ask user whether you want to delete an element if say yes then delete the element and print the new list else print the entered list.
Table: HOSPITAL
| PNo | Name | Age | Department | DateofAdm | Charges | Sex |
| 1 | Mayank | 65 | Surgery | 23/02/2018 | 600 | M |
| 2 | Babita | 24 | ENT | 01/01/2019 | 400 | F |
| 3 | Kashish | 45 | Orthopaedic | 19/12/2018 | 400 | M |
| 4 | Tarun | 12 | Surgery | 01/10/2018 | 600 | M |
| 5 | Manisha | 36 | ENT | 12/01/2018 | 400 | F |
| 6 | Imran | 16 | ENT | 24/02/2018 | 400 | M |
| 7 | Ankita | NULL | Cardiology | 20/08/2018 | 800 | F |
| 8 | Zoya | 45 | Gynecology | 22/02/2018 | 500 | F |
| 9 | Kush | 19 | Cardiology | 13/01/2019 | 800 | M |
| 10 | Shalini | 31 | Medicine | 19/02/2018 | 300 | F |
Note: PNo is the primary key in the above table.
Write SQL commands for the statements (a) to (g) on the table HOSPITAL.
(a) To show all the information about the patients of the cardiology department.
(b) To list the names of female patients who are either in the orthopaedic or surgery department.
(c) To list the name of all the patients with their date of admission in ascending order.
(d) To display the patient’s name, charges, the age for female patients only.
(e) To count the number of patients with age > 30.
(f) To display various departments.
(g) To display the number of patients in each department.
Distances between various buildings:
| Building “RAVI” to Building “JAMUNA” | 120m |
| Building “RAVI” to Building “GANGA” | 50m |
| Building “GANGA” to Building “JAMUNA” | 65m |
| Faridabad Campus to Head Office | 1460km |
Number of computers:
| Building “RAVI” | 25 |
| Building “JAMUNA” | 150 |
| Building “GANGA” | 51 |
| Head Office | 10 |
(a) Suggest the most suitable place (i.e. block) to house the server of this organization. Also give a reason to justify your suggested location.
(b) Suggest a cable layout of connections between the buildings inside the campus.
(c) Suggest the placement of the following devices with justification:
(i) Switch
(ii) Repeater
(d) The organization is planning to provide a high speed link with its head office situated in KOLKATA using a wired connection. Which of the following cable will be most suitable for this job?
(i) Optical Fiber
(ii) Co-axial cable
(iii) Ethernet cable
Write a program which accepts a sequence of commaseparated numbers from console and generate a list and a tuple which contains every number.
Suppose the following input is supplied to the program:
23,45,67,78,89
Then, the output should be:
['23', '45', '67', '78', '89']
('23', '45', '67', '78', '89')