Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

In Python pls 1a) Write a line of code to get an int from the user and assign it to variable x. 1b) Print the

In Python pls

1a) Write a line of code to get an int from the user and assign it to variable x.

1b) Print the square root of the user's number, rounded to two decimal places.

2) Given that var1 = "python":

2a) Write a line of code to print the length of var1.

2b) Write a line of code to assign to variable x the letters "th" from var1 by slicing.

2c) Write a line of code to assign to variable y the letter "h" from var1 by using it's index.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Students also viewed these Databases questions