12th Standard Syllabus & Materials
12th Standard
TN 12th English Poem - 6 - Incident of the French Camp Sample Question Papers Study Material - QB365 Set A
NEW12th Standard
TN 12th English Prose - 6 - On the Rule of the Road Sample Question Papers Study Material - QB365 Set A
NEW12th Standard
TN 12th English Prose - 5 - The Chair Sample Question Papers Study Material - QB365 Set A
NEW12th Standard
TN 12th English Supplementary - 4 - The Midnight Visitor Sample Question Papers Study Material - QB365 Set A
NEW12th Standard
TN 12th English Poem - 4 - Ulysses Sample Question Papers Study Material - QB365 Set A
NEW12th Standard
TN 12th English Prose - 4 - The Summit Sample Question Papers Study Material - QB365 Set A

Published on: 13/05/2022
QB365 provides detailed and simple solution for every book back questions in class 12 Computer Applications subject.It will helps to get more idea about question pattern in every book back questions with solution.
latest Book back QuestionsDownload Tamil Nadu 12th Standard Computer Applications 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 Applications Test

1.
Explain working of loops in array
2.
Explain ‘for’ loop with example.
3.
Explain the process Do while loop.
4.
Discuss in detail about For each loop.
5.
Explain Looping Structure in PHP.
1.
1. The array concepts in looping structure is used in for each loop.
2. For each loop is exclusively available in PHP. It works only with arrays.
3. The loop iteration depends on each KEY value pair in the array. In for each, loop iteration the value of the current array element is assigned to $value variable and the array pointer is shifted by one until it reaches the end of the array element.
4. For each works only on arrays and objects, and will issue an error when you try to use it on a variable with a different data type or an uninitialized variable.
Syntax:
for each ($ array as $ value)
{
code to be executed;
}
1. The for each statement is used to loop through arrays.
2. 'For each' pass the value of the current array element is assigned to $value and the array pointer is moved by one and in the next pass next element will be processed.
Example:
$array = array (1, 2, 3);
{
echo "Value is $value
";
}
?>
Output:
Value is 1
Value is 2
Value is 3
2.
'for loop' is called as the entry-check loop.
The for loop is used to execute a block of code a specific number of times.
Syntax:
for (initialization; condition; increment / decrement)
{
//code to be executed;
}
The initialization part is executed only once at the beginning of the loop. It is used to initialize variables. The condition is evaluated before each iteration of the loop. If it is true, the code block is executed. If it is false, the loop is terminated. The increment/ decrement part is executed after each iteration of the loop. It is used to update variables.
Example 1
To print the numbers from 1 to 5 in ascending order
for (i = 1;
i<=5;
i++)
{
echo i. "<br>";
}
Output:
1
2
3
4
5
Example 2
To print the numbers from 5 to 1 in descending order
for (i = 5;
i<=1;
i--)
{
echo i. "<br>";
}
Output:
5
4
3
2
1
3.
Do while loop always run the statement inside of the loop block at the first time of execution. Then it checks the condition whether true or false. It executes the loop, if the specified condition is true.
Syntax:
do
{
code to be executed;
} while (condition is true);
Example
\(\$\)Student_count = 10;
\(\$\)student_number= 1;
do
{
echo "The student number is: \(\$\)student_number
";
\(\$\)student_number++ ;
}
while(\(\$\)student_number< = \(\$\)Student_count);
?>

4.
1. The foreach statement is used to loop through arrays.
2. The loop iteration depends on KEY value pair in the array.
3. In the loop iteration, the value of the current array element is assigned to $value and the array pointer is shifted by one until it reaches the end of the array element.

Syntax
for each ($array as $value)
{
code to be ex
}
Examples:
for each ($student_name as $value)
{
echo $value
";
}
?>
Output:
Sriakshaya
Sriram
Srisai
Srivatchan
5.
Looping structure are useful for writing iteration logics. It is the most important feature of many programming languages including PHP.
Looping categories are
(i) for loop
(ii) for each loop
(iii) while loop
(iv) Do while loop
(i) for loop:
It is used for iteration logics when the programmer know in advance how many times the loop should run.
Syntax:
for (init counter; test counter; increment counter)
{
code to be executed;
}
Parameters:
init counter: To initialize the loop initial counter value
test counter : Evaluated for every iteration, of the loop.
If it evaluates to TRUE, the loop continues.
If it evaluates to FALSE, the loops ends.
Increment counter:Increases the loop counter value.
(ii) for each loop:
It works only with arrays.
Loop iteration depends on each KEY value pair in the Array.
In loop iteration, value of the current array element is assigned to $value variable and the array
pointer is shifted by one until it reaches the end of the array element.
Syntax:
for each ($array as $value)
{
code to be executed;
}
(iii) While loop:
It is used for simple iteration logics.
It checks the condition, if the condition is true, and it executes the loop.
Syntax:
while (condition is true)
code to be executed;
}
(iv) Do while loop:
Do while loop always run the statement inside the loop block at the first time of execution. It then checks the condition. If the specified condition is true, it executes the loop.
Syntax:
do
{
code to be executed;
}while (condition is true);
}
12th Standard Syllabus & Materials
12th Standard
TN 12th English Supplementary - 3 - The Hour of Truth (Play) Sample Question Papers Study Material - QB365 Set A
NEW12th Standard
TN 12th English Poem - 3 - All the World’s a Stage Sample Question Papers Study Material - QB365 Set A
NEW12th Standard
TN 12th English Prose - 3 - In Celebration of Being Alive Sample Question Papers Study Material - QB365 Set A
NEW12th Standard
TN 12th English Supplementary - 2 - Life of Pi 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