BUGSPOTTER

Most important data science interview questions for real time interview

  1. What is python, def, dynamic, interpreter, high level
  2. what are the diff library of python
  3. what is operators
  4. what is floor division
  5. what are the data types
  6. what are the data structures
  7. what is diff bet data structure and data type
  8. what is mean by mutable and immutable
  9. what is pep 8
  10. diff in list and tuple
  11. diff in list and set
  12. diff in list and disc
  13. diff in tuple and disc
  14. diff in set and disc
  15. diff bet string and int
  16. diff bet int and float
  17. what is shallow copy and deep copy
  18. what is global and local variable in python
  19. what are the rules for the variable or what is identifier
  20. what is generator
  21. what is decorator
  22. what is garbage collector
  23. what is mean by exception handling or error handling
  24. what are the types of error handling
  25. what is indexing
  26. on which data types we can use indexing
  27. what is class
  28. what is constructor
  29. what is fun and method in python
  30. what are the types of variable in class
  31. what are the types of class
  32. what is super function in class
  33. what is overloading and overriding
  34. what is pass in class
  35. what is module and packages in python
  36. what is higher order fun in python
  37. what is map filter reduce in python
  38. what is lambda fun in python
  39. why we use lambda
  40. what is list comprehension in python
  41. what is scope in python

Pandas

1.What is Pandas, and how does it differ from other data manipulation libraries in Python?

2.How do you read data into a Pandas DataFrame from various data sources like CSV, Excel, or SQL databases?

3.What are some common data cleaning and preparation techniques you can use with Pandas, and how do you implement them?

4.Can you walk us through the process of filtering and slicing data in a Pandas DataFrame based on specific conditions or criteria?

5.How do you handle missing data in a Pandas DataFrame, and what options are available for imputing or dropping missing values?

6.What is lock and ilock in pandas

 7.what is shape.

 

Write a program for find largest second number from list

l =[10,20,30,30,30,40,4,4,4,4]

max1 = l[0]

smax = l[0]

for i in l:

    if i>max1:

        smax = max1

        max1 = i

    elif smax<i and i!=max1:

        smax = i

OR

def secondmax(l):

  list1 = [i for i in l if i < max(l)]

  return max(list1)

secondmax([10,20,30,30,30,4,4,4,4,4])

Write a query to fetch details of employees whose EmpLname ends with an alphabet ‘A’ and contains five alphabets.

Select * from employee

Where ename like ‘%a’  and CHAR_LENGTH(ename) = 5;

 

how to calculate even and odd records form table?

Query to find even record:

SELECT * FROM EMPLOYEE

WHERE id IN(SELECT id FROM EMPLOYEE WHERE id%2
= 0)

 Query to find odd record:

SELECT * FROM EMPLOYEE

WHERE id IN(SELECT id FROM EMPLOYEE WHERE id%2
<> 0)

 ‘Write a query to retrieve duplicate records
from a table?

SELECT OrderID, COUNT(OrderID)

FROM Orders

GROUP BY OrderID

HAVING COUNT(OrderID) > 1

 

Fetch 5th highest the salary without limit
and top

select * from(select ename, salary,
dense_rank() over(order by salary desc)r from Emp) where r=5

 

Write query for drop duplicate records

Select *, count(id)

From table_name

Group by id

Having count(id)=1

 

 Now, assume that you have two
tables: “employees” and “salaries”.

The employee table has basic information: ID,
first name, last name, email address, address etc.

Salaries table has employee-id and salary. Query
to be executed is the same: “List names of all the employees

whose salary is greater than or equal to
Rita’s salary”.

ans: select e.first_name from employee e

inner join salary s

on e.id = s.id

where s.salary > = (select s.salary from
employee e

inner join salaries s

on e.id = s.id and e.first_name = ‘reeta’);

  •  What is foreign key and primary key
  • Why foreign key needed in sql
  • what is index in sql
  • what view and table and why view is needed in sql
    what is where and group by
  • what is metadata
  • what is dimensional table
  • what is star schema
  • aws glue and athena

 

 

 

Best Data Science Course In Thane

Best Data Science Course In Thane With Placement 100% Placement...

Read MoreNovember 20, 2024

Best Data Science Course In Satara

Best Data Science Course In Satara With Placement 100% Placement...

Read MoreNovember 20, 2024

Best Data Science Course In Sambhaji Nagar

Best Data Science Course In Sambhaji Nagar With Placement 100%...

Read MoreNovember 20, 2024

Best Data Science Course In Solapur

Best Data Science Course In Solapur With Placement 100% Placement...

Read MoreNovember 19, 2024

Enroll Now and get 5% Off On Course Fees