12th Standard Syllabus & Materials
12th Standard
TN 12th Computer Applications மின்னணு தரவு பரிமாற்றம் Sample Question Papers Study Material - QB365 Set A
NEW12th Standard
TN 12th Computer Applications மின் - வணிக பாதுகாப்பு அமைப்புகள் Sample Question Papers Study Material - QB365 Set A
NEW12th Standard
TN 12th Computer Applications மின்னணு செலுத்தல் முறைகள் Sample Question Papers Study Material - QB365 Set A
NEW12th Standard
TN 12th Computer Applications மின் - வணிகம் Sample Question Papers Study Material - QB365 Set A
NEW12th Standard
TN 12th Computer Applications திறந்த மூல கருத்துருக்கள் Sample Question Papers Study Material - QB365 Set A
NEW12th Standard
TN 12th Computer Applications வலையமைப்பு வடமிடல் Sample Question Papers Study Material - QB365 Set A

Published on: 05/09/2022
QB365 provides a detailed and simple solution for every Possible Book Back Questions in Class 12 Computer Science Subject - Python - Variables and Operators , English Medium. It will help Students to get more practice questions, Students can Practice these question papers in addition to score best marks.
Download Tamil Nadu 12th Standard Computer Science question papers, model tests, one-mark questions, important questions, and public exam papers in PDF format. Free study materials and answer keys for TN State Board students.
Questions + Answers key
Take MCQ Computer Science Test

1.
What are string literals? Explain.
2.
Write short notes on Escape sequences with examples.
3.
Explain Ternary operator with examples.
4.
5.
Write short notes on Arithmetic operator with examples.
1.
(i) In Python, a string literal is a sequence 0 characters surrounded by quotes. Python supports Single, double and triple quotes for a string.
(ii) A character literal is a single character surrounded by single or double quotes. The value with triple-quote u ''' ''' is used to give multi-line string literal.
Program:
To test String Literals:
# Demo Program to test String Literals
strings = "This is Python"
char = "C"
multiline_str = ''''This is a multiline string with more than one line code.'''
print (strings)
print (char)
print (multiline_str)
# End of the Program
Output:
This is Python
C
This is a multiline string with more than one line code.
2.
(i) In Python strings, the backslash "\" is a special character, also called the"escape" character.
(ii) It is used in representing certain whitespace characters: "\t" is a tab, "\n\" is a newline, and "\r" is a carriage return.
(iii) For example to print the message "It's raining", the Python command is
>>> print ("It \ 's raining")
It's raining
Python supports the following escape sequence characters.
| Escape sequence characters | Description | Example | Output |
| \\ | Backslash | >>> print('\\ test") | \test |
| \' | Single - quote | >>> print("Doesn\'t") | Doesn't |
| \'' | Double - quote | >>>print("\"'python\"") | "python" |
| \n | New line | Print ("python"\n","lang..") | Python lang. |
| \t | Tab | Prlnt ("python'","\t","lang.,") | Python lang.. |
3.
(i) Ternary operator is also known as conditional operator that evaluate something based on a condition being true or false.
(ii) It simply allows testing a condition in a single line replacing the multiline if-else making the code compact. The syntax for conditional operator is,
Variable Name = [on_true] if [Test expression]
else [on_false]
(iii) Example:
min = 50 if 49 < 50 else 70 # min = 50
min = 50 if 49 > 50 else 70 # min = 70
4.
5.
(i) An arithmetic operator is a mathematical operator that takes two operands and performs a calculation on them. They are used for simple arithmetic.
(ii) Most computer languages contain a set of such operators that can be used within equations to perform different types of sequential calculations.
(iii) Python supports the following Arithmetic operators.
| Operator-Operation | Examples | Result |
| Assume a=100 and b=10 Evaluate the following expressions | ||
| + (Addition) | >>> a+b | 110 |
| - (Subtraction) | >>> a-b | 90 |
| * (Multiplication) | >>> a*b | 1000 |
| / (Division) | >>> a/b | 10.0 |
| % (Modulus) | >>> a%30 | 10 |
| ** (Exponent) | >>> a**2 | 10000 |
| // (Floor Division) | >>> a// 30 (Integer Division) | 3 |
12th Standard Syllabus & Materials
12th Standard
TN 12th Computer Applications களப்பெயர் முறைமை (DNS) Sample Question Papers Study Material - QB365 Set A
NEW12th Standard
TN 12th Computer Applications வலையமைப்பு எடுத்துக்காட்டுகள் மற்றும் நெறிமுறைகள் Sample Question Papers Study Material - QB365 Set A
NEW12th Standard
TN 12th Computer Applications கணினி வலையமைப்பு ஓர் அறிமுகம் Sample Question Papers Study Material - QB365 Set A
NEW12th Standard
TN 12th Computer Applications PHP-உடன் MySQL-ஐ இணைத்தல் Sample Question Papers Study Material - QB365 Set A
Tamilnadu Stateboard 12th Standard Subjects

Maths

Chemistry

Physics

Biology

Computer Science

Business Maths and Statistics

Economics

Commerce

Accountancy

History

Computer Applications

Biology

Computer Technology

Computer Applications

Computer Science

Business Maths and Statistics

Commerce

Economics

Maths

Chemistry

Physics

Computer Technology

History

Accountancy

Tamil

English

French
Tamilnadu Stateboard Standards