Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
0% found this document useful (0 votes)
19 views

Notes On Python

Python is widely used for artificial intelligence applications because it is the primary programming language used by data scientists and engineers to build sophisticated AI systems. Some key benefits of Python include being simple to read and maintain, having a clear syntax, including many built-in functions, supporting interactive testing and debugging, and running on various operating systems. Python can be used for web development, desktop applications, software development, database access, business applications, and games.

Uploaded by

sejalsingh387
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
19 views

Notes On Python

Python is widely used for artificial intelligence applications because it is the primary programming language used by data scientists and engineers to build sophisticated AI systems. Some key benefits of Python include being simple to read and maintain, having a clear syntax, including many built-in functions, supporting interactive testing and debugging, and running on various operating systems. Python can be used for web development, desktop applications, software development, database access, business applications, and games.

Uploaded by

sejalsingh387
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 5

Question answer on Python

1. What is the purpose of Python in AI?


Answer – Python is at the heart of every modern artificial intelligence system. It’s the programming
language of choice for data scientists and engineers creating the key infrastructure that drives today’s
most sophisticated AI systems. As a result, many companies are using Python to develop their next
generation of AI systems.

2. What are the benefits of Python Language?


Answer – The benefits of Python Language are

1. Simple to understand, read, and maintain

2. Clear syntax and a simple keyword structure

3. Python includes a large library of built-in functions that can be used to tackle a wide range of
problems.

4. Python features an interactive mode that enables interactive testing and debugging of code snippets.

5. Python runs on a wide range of operating systems and hardware platforms, with the same user
interface across all of them.

6. We can use the Python interpreter to add low-level models. These models allow programmers to
make their tools more efficient by customizing them.

7. Python includes interfaces to all major open source and commercial databases, as well as a more
structured and robust framework and support for big systems than shell scripting.

3. What are the different applications of Python?


Answer – The different application of Python are –
Web and Internet Development
2. Desktop GUI Application
3. Software Development
4. Database Access
5. Business Application
6. Games and 3D Graphics

4. What do you mean by Interactive Mode in Python shell?


Answer – Python IDLE Shell has a Python prompt where you can type single-line Python commands and
have them executed quickly.

5. What do you mean by Script Mode in Python Shell?


Answer – The Script Mode in Python allows you to add many lines of code. In script mode, we write a
Python programme to a file and then run it using the interpreter. Working in interactive mode is
advantageous for beginners and for testing small sections of code because it allows us to test them
immediately. When developing code with more than a few lines, however, we should always save it so
that we can change and reuse it later.

6. What is a python Statement?


Answer – A statement is a piece of code that a Python interpreter can execute. In other terms, a
statement is anything typed in Python. There are many different types of statements in the Python
programming language, including assignment statements, conditional statements, looping statements,
and so on.

7. What are Keywords?


Answer – In Python, keywords are reserved words that help the interpreter recognise the program’s
structure. Keywords are predefined terms in Python that have special meanings. The keyword isn’t
allowed to be used as a variable, function, or identifier. With the exception of True and False, all Python
keywords are written in lower case.

8. What are Identifiers?


Answer – A variable, function, class, module, or other object is given a name called an identifier. A string
of numerals and underscores make up the identifier. The identifier should start with a letter or an
Underscore and end with a numeric. The characters are A-Z or a-z, an UnderScore (_), and a numeric (0-
9). In identifiers, special characters (#, @, $, %,!) should be avoided.

9. What is Variable?
Answer – In a computer language, a variable is a memory area where a value is assign. A variable in
Python is created when a value is assigned to it. In Python, declaring a variable does not necessitate any
additional commands.

10. What are the different rules for declaring the Variable?
Answer – The rules for declaring variable are –
1. A number cannot be used as the first character in the variable name. Only a character or an
underscore can be used as the first character.
2. Python variables are case sensitive.
3. Only alpha-numeric characters and underscores are allowed.
4. There are no special characters permitted.

You might also like