Skip to content

Latest commit

 

History

History
65 lines (55 loc) · 1.97 KB

index.md

File metadata and controls

65 lines (55 loc) · 1.97 KB

PyTutorials - Home

print("Hello World!")

Home | Tutorials | Signup
Submit You can't signup or search for different pages if Javascript isn't enabled.

<script src="search.js"></script> <script src="errorhandle.js"></script> <script src="login.js"></script> <script src="timesVisited.js"></script> <script> if(localStorage.getItem("banned")){ window.location.assign("banned.html"); } </script> #### Home

Example 1

  • Output Hello World
print("Hello World!") #This outputs the text Hello World!

Example 2

  • Get a list of files in the current directory and output them
import os
files = []
for file in os.listdir():
  if os.path.isfile(file):
   if file == "yourfile.py":
     continue
   else:
     files.append(file)
  else:
     continue

Example 3

* Comments
#This is a comment it is usually used to explain what your code does. The computer ignores this.
"""This is a multiline comment"""

For more examples click this link

Test your code here

Add Recomendations Python examples About this project

This project is closed source. What is closed source?

Written in HTML, Markdown, CSS, and JavaScript. Go back to the top of the page Make sure the url is pytutorials.github.io