Answer:
Following are the program in the Python Programming Language:
def check(num): #define function
if(num.isdigit()): #set if statement
return "yes"; #return yes if condition is true
else:
return "no";# return no if condition is false
string=input("Enter the numbers 0-9: ") #get input from the user
print(check(string)) #print and call the function
Output:
Enter the numbers 0-9: 1995
yes
Enter the numbers 0-9: 42,000
no
Explanation:
Here, we define a function "check()" and pass an argument in its parameter "num" inside the function.
- we set if-else conditional statement and check the value stored in the variable "num" is the digit by using built in function "isdigit()" then return "yes".
- Then, otherwise it return "no".
Finally, we get the input from the user in the variable "string" then, we call the function through "print()" function.
45, 78, 23, 12, 63, 90, 38, 56, 88, 15 Using the sequential search as described in this chapter, how many comparisons are requir
Alecsey [184]
Explanation:
By using the sequential search we find the following results.
- The first key is 90 and its comparison number is 6.
- The second key is 14 and its comparison number is 10.
- The third key is 45 and its comparison number is 1.
- The fourth key is 23 and its comparison number is 3.
- The fifth key is 5 and its comparison number is 10.
Answer:
When the drums revolution is completed, the toner still remaining on the photoreceptor drum is cleaned by a plastic blade that is made of soft electrically neutral material which then deposits waste toner into a toner reservoir in the printer. The drum is then charged to become uniformly negatively charge by a rolling charger to prepare the drum for the beam from the laser.
Explanation:
total = 0
i = 0
while i < 10:
temp = float(input("Enter Temperature: "))
total += temp
i += 1
print("Sum = "+str(total))
I hope this helps!
Brightness is the answer, I hope this was helpful.