Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Python Basic #431

Open
Mrgamji opened this issue Feb 21, 2023 · 8 comments
Open

Python Basic #431

Mrgamji opened this issue Feb 21, 2023 · 8 comments

Comments

@Mrgamji
Copy link

Mrgamji commented Feb 21, 2023

No description provided.

@Mrgamji
Copy link
Author

Mrgamji commented Feb 21, 2023

Anyone with knowledge of reversed(range()) for for loop?

@carlosfran
Copy link

Anyone with knowledge of reversed(range()) for for loop?

for i in range(5, 0, -1):
    print(i)

@ezimoha-obichukwu
Copy link

Anyone with knowledge of reversed(range()) for for loop?

for i in range(8, 0, -1):
print(i)

@Mrgamji
Copy link
Author

Mrgamji commented Apr 6, 2023

for i in reversed(range(0,5,1)):
print(i)

@Saunakghosh10
Copy link

In Python, the range() function generates a sequence of numbers. When combined with the reversed() function, it reverses the order of the numbers generated by range(). Here's an example:
for i in reversed(range(5)):
print(i)

@haitao888
Copy link

haitao888 commented Jul 14, 2023 via email

@lxl0506
Copy link

lxl0506 commented Jul 14, 2023 via email

@haitao888
Copy link

haitao888 commented Nov 17, 2023 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants