in the future - u will be able to do some more stuff here,,,!! like pat catgirl- i mean um yeah... for now u can only see others's posts :c
What will be the output of the following Python code snippet?
def add(x, y):
" " " Add the numbers x and y and return it " " "
return x + y
print(add.__doc__)
2 - 0
What will be the output of the following Python code snippet?
squares = [ ]
for n in range(3):
squares.append(n*n)
print(squares)
3 - 0
What is the output of the following Python print statement?
print(isinstance(5.0, (str, int, dict, list, tuple)))
4 - 0
What will be the output of the following Python statements?
my_list = [1,2,3,4,5,6,7,8,9]
my_new_list = list(filter(lambda x: (x%2 != 0) , my_list))
print(my_new_list)
2 - 0
Execute the following Python statements in your Python interpreter and enter a few numbers.
x=list(map (float, input("Enter few numbers separated by space: ").split()))
print(x)
Isn't it interesting? Is x a list or a tuple or a set? You may share your response as a comment.
0 - 2
The .pyc file is the compiled version of the Python source file (.py). If .pyc file exists for a source file (.py) and if it is newer than the corresponding .py file, the Python interpreter skips recompiling (translating) the .py file again. That is .pyc file speeds things up.
2 - 0
SuMyPyLab
Welcome to SuMyPyLab, your ultimate destination for mastering Python programming and Data Science Concepts. Whether you're a beginner looking to embark on your coding journey or an experienced developer seeking to deepen your skills, this channel is designed to cater to all levels of expertise.
The step-by-step guides and hands-on examples will help you grasp Python fundamentals, explore object-oriented programming, and tackle real-world coding challenges. Learning by doing is the theme of this channel, so get ready to write code that are concise, useful and well-tested.
The tech world evolves rapidly, and so do programming languages and database technologies. Stay updated with the latest trends, best practices, and emerging tools through our regular updates and discussions.