code
stringlengths 3
157
| text
stringlengths 6
207
|
---|---|
if N < 0:
print("negative number") | Print 'negative number' if variable N is less than zero |
if N < 0:
print("negative number") | If variable N is less than zero, print it as 'negative number' |
if N < 0:
print("negative number") | Print 'negative number' if variable N is less than zero |
if N < 0:
print("negative number") | If variable N is less than zero, print 'negative number' |
if N < 0:
print("negative number") | If variable N is smaller than zero, print it as a 'negative number' |
if N < 0:
print("negative number") | Print 'negative number' if variable N is less than zero |
elif N == 0:
print("zero") | If not, print 'zero' if variable N is zero |
elif N == 0:
print("zero") | Print 'null' if otherwise variable n is null |
elif N == 0:
print("zero") | Print 'null' if otherwise variable n is null |
elif N == 0:
print("zero") | If not, print 'zero' if variable N is zero |
else:
print("positive number") | If not, print as Positive Number |
else:
print("positive number") | If not, print positive number |
else:
print("positive number") | If not, print as Positive Number |
else:
print("positive number") | If not, print positive number |
else:
print("positive number") | If not, print as a positive number |
else:
print("positive number") | If not, print as a positive number |
x=13 | Assign number thirteen to variable X |
x=13 | Assign number thirteen to variable X |
x=13 | Store number thirteen in variable X |
factorial =1 | Assign number one to variable factorial |
factorial =1 | Assign number one to variable factorial |
if x <0:
print("error") | Print 'error' if less than X zero |
if x <0:
print("Error") | If the value of X is less than zero, print "Error |
elif x==0:
factorial =1 | Or assign one to the factorial if the X value is zero |
elif x==0:
factorial =1 | Or assign one to the factorial if the X value is zero |
for i in range(1,14): | Or enforce a for loop,from one to fourteen |
for i in range(1,14): | Or enforce a for loop,from one to fourteen |
for i in range(1,14): | Or enforce a for loop, from one to fourteen |
factorial*=i | Update factorial as factorial *i |
factorial*=i | Update factorial as factorial *i |
print(factorial) | Print Factorial |
print(factorial) | Print Factorial |
N = int(input("Enter N : ")) | Declare variable N and assign user input numeric value |
N = int(input("Enter N : ")) | Declare variable N and store user input number in it |
N = int(input("Enter N : ")) | Declare variable N and store user input number value in it |
N = int(input("Enter N : ")) | Declare variable N and assign user input numeric value to N |
N = int(input("Enter N : ")) | Declare the variable N and collect the user-given number in it |
N = int(input("Enter N : ")) | Assign user input number to variable N |
if N > 1: | If Variable N is more than one |
if N > 1: | If variable N is greater than 1 |
if N > 1:
for i in range(2, N//2 + 1): | Start for loop with i from 2 to n/2+1 if variable n is greater than one |
if N > 1:
for i in range(2, N//2 + 1): | Start for loop with i from 2 to n/2+1 if variable n is more than one |
if N > 1:
for i in range(2, N//2 + 1): | Start for loop with i from 2 to n/2+1 if variable n is greater than one |
if N > 1:
for i in range(2, N//2 + 1): | Start for loop with i from 2 to n/2+1 if variable n is more than one |
if (N % i) == 0:
print("N is not a prime number")
break | Inside the loop, print the 'N is not a prime number' if variable N can be divided by i |
else:
print("N is a prime number") | Otherwise print as 'N is a prime number' |
else:
print("N is not a prime number") | If not, then print 'N is not a prime number' if N is less than or equal to one |
N = int(input("Enter N : ")) | Declare variable N and assign user input numeric value |
N = int(input("Enter N : ")) | Declare variable N and store user input number in it |
N = int(input("Enter N : ")) | Declare variable N and store user input number value in it |
N = int(input("Enter N : ")) | Declare variable N and assign user input numeric value to N |
N = int(input("Enter N : ")) | Declare the variable N and collect the user-given number in it |
N = int(input("Enter N : ")) | Assign user input number to variable N |
for i in range(1, 11): | For i in range of 0 to 11 |
print(f"{N} x {i} = {N*i}") | Multiply N with i and print the result |
print(f"{N} x {i} = {N*i}") | Multiply N with i and print the result |
N = int(input("Enter N : ")) | Declare variable N and assign user input numeric value |
N = int(input("Enter N : ")) | Declare variable N and store user input number in it |
N = int(input("Enter N : ")) | Declare variable N and store user input number value in it |
N = int(input("Enter N : ")) | Declare variable N and assign user input numeric value to N |
N = int(input("Enter N : ")) | Declare the variable N and collect the user-given number in it |
N = int(input("Enter N : ")) | Assign user input number to variable N |
result = 0 | Now declare the result variable and set it to zero |
result = 0 | Declare the result variable and store zero in it |
result = 0 | Assign zero to the result variable |
result = 0 | Declare the result variable and set it to zero |
result = 0 | Assign zero to the result variable |
result = 0 | Assign zero to the result variable |
while(N > 0): | Now enforce while Loop with a condition that Variable N should be greater than zero |
while(N > 0): | Now start the while Loop with a condition that Variable N should be greater than zero |
while(N > 0): | Start while Loop now with a condition that Variable N should be greater than zero |
while(N > 0): | Now execute the while Loop with the condition that the variable should be greater than N zero |
result += N | Add N to the result variable until the condition is true and store it in the result |
N -= 1 | Subtract one from N until the condition is true |
print(result) | Print the result variable if the condition is false |
while(N > 0): | Execute the while Loop with the condition that now the variable N must be greater than zero |
result += N | Now add the result and variable N inside the loop and collect their sum in the result |
result += N | Now add the result and variable N within the loop and accumulate their sum in the result |
result += N | Now add the result and variable N within the width loop and collect their sum in the result |
result += N | Now add the result and variable N within the width loop and collect their sum in the result |
result += N | Now add the variable N and the result inside the loop and accumulate their sum in the result |
result += N | Now add the variable N and the result inside the loop and assign their sum to a variable called the result |
result += N | Now add the variable N and the result inside the loop and assign their sum to the result variable |
result += N | Now add the variable N and the result to the inside of the loop and store their amount in a variable called result |
result += N | Upgrade result to result += N until the condition is true |
result += N | Update result as result += N until condition is true |
N -= 1 | Subtract one from N inside the loop |
N -= 1 | Now subtract one from N inside the loop |
print(result) | Print result on conditional false |
print(result) | Print the variable force result when the condition is false |
print(result) | Print result on conditional false |
print(result) | Print result on conditional false |
a=24 | Assign number twenty-four to variable a |
a=24 | Assign number twenty-four to variable a |
print("result:") | Print 'Result:' |
for i in range(1,24): | enforce a for loop,from one to twentyfour |
for i in range(1,24): | start a for loop,from one to twenty-four |
for i in range(1,24): | enforce a for loop, from one to twenty-four |
if a%i==0: | If a divisible by i |
if a%i==0: | If a divisible by i |