Write definition of a function MSEARCH(STATES) to display all the state names from a list of STATES, which are starting with alphabet M.
For example:
If the list STATES contains
The following should get displayed
MP
MH
MZ
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.
| From_To | FlightNumber | RecentDelays | Airline | |
| 0 | NewDelhi_Chennai | 10045.0 | [23, 47] | Spicejet |
| 1 | Mumbai_NewDelhi | NaN | [] | Indigo |
| 2 | Jaipur_Jammu | 10065.0 | [24, 43, 87] | Spicejet |
| 3 | Chennai_Lucknow | NaN | [13] | Indian Airlines |
| 4 | Mumnbai_Chennai | 10085.0 | [67, 32] | Spicejet |
(i) #To display the maximum flight number
(ii) #To print the number of flights airline wise
(iii) #to drop the nan values from the dataframe
(iv) To fill nan with blank values
(v) To print the maximum values of recent delays
(vi) To print the median of all the numeric values.
(vii) To print the sum of the recentdelays
(viii) To count the flight numbers.
(ix) To print the airline wise the sum of the recentdelays along with From_to as column
(x) To print the airline wise the sum of the recentdelays along with From_to as column. Also fill NaN values as blank.
Write SQL commands for the following queries on the basis of Club relation given below:
Relation: Club
| Coach-ID | CoachName | Age | Sports | date_of_app | Pay | Sex |
| 1 | Kukreja | 35 | Karate | 27/03/1996 | 1000 | M |
| 2 | Ravina | 34 | Karate | 20/01/1998 | 1200 | F |
| 3 | Karan | 34 | Squash | 19/02/1998 | 2000 | M |
| 4 | Tarun | 33 | Basketball | 01/01/1998 | 1500 | M |
| 5 | Zubin | 36 | Swimming | 12/01/1998 | 750 | M |
| 6 | Ketaki | 36 | Swimming | 24/02/1998 | 800 | F |
| 7 | Ankita | 39 | Squash | 20/02/1998 | 2200 | F |
| 8 | Zareen | 37 | Karate | 22/02/1998 | 1100 | F |
| 9 | Kush | 41 | Swimming | 13/01/1998 | 900 | M |
| 10 | Shailya | 37 | Basketball | 19/02/1998 | 1700 | M |
(a) To show all information about the swimming coaches in the club.
(b) To list the names of all coaches with their date of appointment (date_of_app) in descending order.
(c) To display a report showing coach name, pay, age, and bonus (15% of pay) for all coaches.
(d) To insert a new row in the Club table with ANY relevant data:
(e) Give the output of the following SQL statements:
(i) Select COUNT(Distinct Sports) from Club;
(ii) Select Min(Age) from Club where SEX = “F ”;
(a) # Line 1 : To open file POEM.txt in read mode
(b) # Line 2 : To check first character of every line is ‘W’ or ‘w’.
(c) # Line 3 : To increase the value of count by 1.
(d) # Line 4 : To call the function count_poem.
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