Sort by

recency

|

1699 Discussions

|

  • + 0 comments

    I'm developing a website and need assistance in adding a Python loop to my code. The loop should generate a sequence of numbers based on specific start, stop, and step values and display the results dynamically on my website. Any advice from those with experience would be highly appreciated.

  • + 0 comments

    n = int(input())

    for i in range(0, n): print(i ** 2)

    [print(x ** 2) for x in range(0, n)]

  • + 0 comments

    for i in range (0,n): print(i*i)

  • + 0 comments

    n = int(input('')) for i in range(0, n): print(i * i) i += 1

  • + 0 comments

    python 3

    n=int(input())

    square =[x**2 for x in range(n)]

    for x in square:

    print(x)