Starting from:

$30

DATA SCIENCE Assignment-2 Solved

Q1. How do you comment code in Python? What are the different types of comments?

Q2. What are variables in Python? How do you declare and assign values to variables?

Q3. How do you convert one data type to another in Python?

Q4. How do you write and execute a Python script from the command line?

Q5. Given a list my_list = [1, 2, 3, 4, 5], write the code to slice the list and obtain the sub-list [2, 3].

Q6. What is a complex number in mathematics, and how is it represented in Python?

Q7. What is the correct way to declare a variable named age and assign the value 25 to it?

Q8. Declare a variable named price and assign the value 9.99 to it. What data type does this variable
belong to?

Q9. Create a variable named name and assign your full name to it as a string. How would you print the
value of this variable?

Q10. Given the string "Hello, World!", extract the substring "World".

Q11. Create a variable named "is_student" and assign it a boolean value indicating whether you are
currently a student or not.
Note: Create your assignment in Jupyter notebook and upload it to GitHub & share that github repository

link through your dashboard. Make sure the repository is public.

More products