Python Tips

Q1: What is Script ?

A: Script is a program that is short , simple and can be written very quickly.

Example : Python Script

Q2 : What is Python Interpreter ?

A: If your recipe is written in Python, the Python interpreter is the program that reads what is in the recipe and translates it into instructions for your computer to follow.

Q3: What is Syntax and Semantics?

A: When writing code, using correct syntax is very important. Even a small typo, like a missing parentheses or an extra comma, can cause a syntax error and the code won’t execute at all.

If your syntax is correct, but the script has unexpected behavior or output, this may be due to a semantic problem. Syntax is the rules of how code is constructed, while semantics are the overall effect the code has.

It is possible to have syntactically correct code that runs successfully, but doesn’t do what we want it to do.

Q4:Why is Python relevant to IT ?

A:

  1. Python is simple and easy to use
  2. Python makes it easy to express the fundamental concepts of programming like data structures and algorithms with easy to read syntax. This makes Python a great language to use to learn programming. 
  3. More tools available in Python for a growing range of applications. 
  4. You can use Python to calculate statistics, run your e-commerce site, process images, interact with web services, and do a whole host of other tasks. 
  5. Python is perfect for automation. It lets you automate everyday tasks by writing simple scripts that are easy to understand and easy to maintain. 
  6. Python is the language of choice for lots of people working in IT support, system administration, and web development. 
  7. It’s also used in fast-growing areas of IT, like machine learning or data analytics. 
  8. Python is available for download on a wide variety of operating systems, like Windows, Linux, and Mac OS. 

Q5 : Most popular online interpreters and codepads. 

A:

Q6: What are Key words ?

A: Keywords are reserved words that are used to construct instructions. These words are the core part of the language and can only be used in specific ways. Some examples include if, while, and for.

For reference, these are all the reserved keywords:

Falseclassfinallyisreturn
Nonecontinueforlambdatry
Truedeffromnonlocalwhile
anddelglobalnotwith
aselififoryield
assertelseimportpass
breakexceptinraise
Information shared by : PALGUNI G T