Download as rtf, pdf, or txt
Download as rtf, pdf, or txt
You are on page 1of 5

35.

1.c. df['House'][(df['Second'] >= 12) & (df['Second'] <= 20)]

2.b. print(df.iloc[::-1])

3.a. print(df.size)

34.

SELECT EmployeeName, ROUND(Bonus, 0) AS RoundedBonus

FROM YourTableName;

SELECT EmployeeName, instr('ee', EmployeeName) AS PositionOfEE

FROM YourTableName;

SELECT EmployeeName, SUBSTR(EmployeeName, 2, 4) AS ExtractedChars

FROM YourTableName;

33.

import matplotlib.pyplot as plt

# Given data

Month = [1, 2, 3, 4]

Scoring_rate = [140, 132, 148, 164]

# Plotting the line chart

plt.plot(Month, Scoring_rate )

plt.xlabel('Month')

plt.ylabel('Scoring Rate')

plt.title('Monthly Scoring Rate of the Batsman')

plt.show()

32.1.

Human Resource

2.satellite link
3.switch/hub

4.no repeater required

5. cb---hrb
fb/

31.1.CURDATE()
2.UPPER('Kendriya')
3.RTRIM('Kvs RO Jammu')
4.month(curdate());
5.POWER(n1, n2)

30.1.SELECTCLASS , SUM(Marks) AS TotalMarks


FROM Students
GROUP BY Class;
2.SELECT Class, COUNT(*) AS HighAchievers
FROM Students
WHERE Marks > 90
GROUP BY Class;
3.SELECT MAX(Marks) AS MaxMarks, MIN(Marks) AS MinMarks
FROM Students;

29.

28.import pandas as pd

# i. Add a column called Qty with the following data: [100, 150, 300, 500]
df['Qty'] = [100, 150, 300, 500]

# ii. Add a new item named 'Bat' having price 550


new_item = {'Item': 'Bat', 'Price': 550}
df = df.append(new_item, ignore_index=True)
# iii. Remove the column 'Price'
df = df.drop('Price', axis=1)

27.import pandas as pd
# List of data
data = [['Shreya', 20], ['Rakshit', 22], ['Srijan', 18], ['Rahul', 25]]
# Column headings
columns = ['Name', 'Age']
# Create a DataFrame
df = pd.DataFrame(data, columns=columns)
# Display the DataFrame
print(df)

26.1

not 8 it is 4
2.

3.

25.i. Shape of DataFrame df: (4, 2)


ii. Column names of DataFrame df:
Index(['A', 'B'], dtype='object')

24.1 25
2 35
dtype: int64

23.Recycling:
E-Waste Collection Events:
Manufacturer Take-Back Programs:
Public Awareness and Education:

22.import pandas as pd
students_dict = {'Class 9': 45, 'Class 10': 50, 'Class 11': 43, 'Class 12': 35}
# Create a pandas Series
students_series = pd.Series(students_dict)
# Display the Series
print(students_series)

21.The GROUP BY clause in SQL is used to group rows based on one or more columns and apply
aggregate functions to each group.

20.

1.COUNT(*) counts all rows, regardless of whether any specific column (in this case, marks) has NULL
values.The output, in this case is 6, indicating that there are 6 rows in the STUDENT table.

2.COUNT(marks) excludes rows where the marks column has NULL values from the count.The output,
in this case, is 5, indicating that there are 5 non-NULL values in the marks column.

19.Web Server:

A web server is a software or hardware system that serves content to users over the internet. It
processes incoming network requests over HTTP (Hypertext Transfer Protocol) and delivers web pages,
images, videos, or other resources to clients (web browsers).

Web Client:

A web client, commonly referred to as a browser, is a software application that enables users to access
and view content on the World Wide Web. Web clients interpret HTML (Hypertext Markup Language)
documents and render them into multimedia content, such as text, images, and interactive elements.

18.Both the assertion and reasoning are correct:

17.The assertion (A) is correct, but the reasoning (R) is incorrect.

16.ii. Plagiarism

15.iv. Online etiquette

14.iii. MONTH()

13.iv. Edge

12.iv. All of these


11.i) Histogram

10.iii. S.head(7)

9.i. MAX( )

8.ii. LENGTH()

7.i. SELECT SUM(Price) FROM ORDERS;

6.(D) All of the above

5.i) 500

4.iii. DELETE

3.iii. Unused old computers

2.iv. Cyber bullying

1.(B) HTTP

You might also like