Answer:
# user is prompted to enter the value of n
n = int(input("Enter your number: "))
# if statement to check if n > 0
if (n > 0):
# for-loop to loop through the value of n
for digit in range(1, (n+1)):
# if digit is odd, print 1
if((digit % 2) == 1):
print("1", end=" ")
# else if digit is even print 0
else:
print("0", end=" ")
Explanation:
The code is written in Python and is well commented.
A sample output of the code execution is attached.
The TCP/IP protocol provides access to internally and externally I.e. The internet.
That term means , of as people, animals , and objects because that is what the internet is contained of . The disadvantages , you wont be able to look at it easily , the advantages , there is not many.
Answer:
The sorting operation
Explanation:
Required
Database operation to view a record in alphabetical order
The operation is sorting.
Literally, this means arranging data in a particular order (e.g. ascending or descending order)
So, after the database has been created, and I need to the arranged list of names of the computer hardware, I will make use of the sorting operation.
Depending on the database management software that I used, the operation can be achieved using SQL queries (e.g. MySQL Workbench) and can also be done manually (e.g. Microsoft Office Access)
Answer:
0.444
Explanation:
Formula for slope = (X2 - X1)/(Y2 - Y1)
X1 =100
X2 = 500
Y1 = 1000
Y2 = 10000
Slope = (500 - 100)/(10000 - 1000)
=400/9000
=4/90
=0.04444
Number of bill(X axis) against sales (Y axis)