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 Creative Questions in Class 12Computer Science Subject - Strings and String Manipulations , 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 is string? How will you create a string?
2.
With an example program explain about membership operators?
3.
Write the out put for the following statement.
strl = "Raja Raja Chozhan"
(i) print (strl. count ('Raja'))
(ii) print (strl. count ('R'))
(iii) print (strl. count ('A'))
(iv) print (strl. count ('a'))
(v) print (strl. count ('a', 0, 5))
(vi) print (strl. count ('a', 11))
4.
Write a note on
(i) isalnum ()
(ii) isalpha ()
(iii) isdigit ()
5.
Write the output for the following statement.
(i) print ("PYTHON" . lower ())
(ii) print ("PYTHON" . islower ())
(iii) print ("PYTHON" . isupper ())
(iv) print ("PYTHON" . upper ())
6.
Write the output of the following statements.
(i) 'Python 2.3' . isalpha ()
(ii) 'Python Program' . is alnum ()
(iii) 'Python' . isupper ()
7.
Write the output of the following statements.
strl = 'mammals'
(i) std. find ('ma')
(ii) std. find ('ma', 2)
(iii) std. find ('ma', 2, 4)
(iv) std. find ('ma', 2, 5)
8.
Write the output of the following statements.
(i) print (len ("Corporation"))
(ii) print ("school", Capitalize ())
(iii) print ("Welcome" center (15, '*'))
9.
Write the description for the following escape sequence.
(i) \r
(ii) \000
(iii) \v
10.
Write the formats string characters for the following
(i) Exponential notation
(ii) Floating point numbers
(iii) Short numbers in exponential notation
11.
Fill in the blanks.
| Format character | Usage | |
| i) | ________ | Unsigned decimal integer |
| ii) | %0 | _______ |
| iii) | _______ | Hexadecimal integer |
| iv) | %i | _______ |
12.
Write the usage of the following format string characters.
(i) % c
(ii) % d (or) % i
(iii) % s
13.
Write the syntax and example of using string characters.
14.
Write a program to accept a string and print it in reverse order.
15.
How the positive and negative subscript values are assigned? Give example.
1.
String is a data type in python, which is used to handle array of characters. String is a sequence of Unicode characters that may be a combination of letters, numbers or special symbols enclosed within single, double or even triple quotes.
Example:
'Welcome to learning python'
"Welcome to learning python"
""Welcome to learning python""
In Python, strings are immutable, it means once we define a string, it cannot be changed during execution.
Creating Strings:
A string in Python can be created using single or double or even triple quotes. String in single quotes cannot hold any other single quoted character in it, because the compiler will not recognize where to start and end the string. To overcome this problem, we have to use double quotes. Strings which contains double quotes should be define within triple quotes. Defining strings within triple quotes also allows creation of multiline strings.
2.
Membership Operators:
(i) The 'in' and 'not in' operators can be used with strings to determine whether a string is present in another string. Therefore, these operators are called as Membership Operators.
(ii) Example:
str1=input ("Enter a string:")
str2="chennai"
if str2 in str1:
print ("Found")
else:
print ("Not Found")
(iii) Output:1
Enter a string: Chennai GHSS, Saidapet
Found
(iv) Output:2
Enter a string: Govt GHSS, Ashok Nagar Not Found
3.
(i) 2
(ii) 2
(iii) 0
(iv) 5
(v) 2
(vi) 1
4.
| Syntax | Description | Example | |
| (i) | isalnum () | Returns True if the string contains only letters and digit. It returns False. If the string contains any special character like _,@,#,*,etc. |
>>>str1='Save Earth' >>>str1.isalnum() False The function returns False as space is an alphanumeric character. >>>'save 1 Earth'. isalnum() True |
| (ii) | isalpha () | Returns True if the string contains only letters Otherwise return False. |
>>>'Click123'. isalpha() False >>>'python'.isalpha() True |
| (iii) | isdigit () | Returns True if the string contains only numbers. Otherwise it returns False |
>>>str1='Save Earth' >>>print(str1.isdigit()) |
5.
(i) python
(ii) false
(iii) false
(iv) PYTHON
6.
(i) False
(ii) False
(iii) False
7.
(i) 0
(ii) 3
(iii) -1
(iv) 3
8.
(i) 11
(ii) School
(iii) * * * * Welcome * * * *
9.
(i) carriage return
(ii) character with octal value
(iii) vertical tab
10.
(i) % e or % E
(ii) % f
(iii) % g or % G
11.
(i) %u
(ii) octal integer
(iii) %c or %x
(iv) signed decimal integer.
12.
(i) character
(ii) Signed decimal integer
(iii) String
13.
Syntax:
("String to be display with %vall and %vaI2" %(val1, vaI2))
Example:
name = "Rajarajan''
mark = 98
print ("Name: %s and Marks: %d" %(name,mark) )
Output:
Name: Rajarajan and Marks: 98
14.
str1 = input ("Enter a string:")
Index=-1
while index >= -(lentstrl1)):
print ("Subscript[",index,"] :" + str1 [index])
index +=-1
Output:
Enter a string: welcome
Subscript [ -1 ] : e
Subscript [ -2 ] : m
Subscript [ -3 ] : 0
Subscript [ -4 ] : c
Subscript [ -5 ] : I
Subscript [ -6 ] : e
Subscript [ -7 ] : w
15.
The positive subscript 0 is assigned to the first character and n-1 to the last character, where n is the number of charaters in the string. The negative index assigned from the last character to the first character in reverse order begins with -1.
Example:
| String | S | C | H | O | O | L |
| Positive subscript | 0 | 1 | 2 | 3 | 4 | 5 |
| Built in functions | -6 | -5 | -4 | -3 | -2 | -1 |
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