Answer:
Do this:
Position the insertion pointer where you want the index to appear. If you want the index to start on a new page, create a new page in Word. ...
Click the References tab.
In the Index group, click the Insert Index button. The Index dialog box appears. ...
Click the OK button to insert the index into your document.
Answer: In operating system a code segment which accesses some shared variables or resources one at a time atomically such other no other code or process is accessing that resource or variable at the same time.
Entry section code block allows the access to the shared resource or variable and exit section code signals the termination from access to the shared resource or variable.
Explanation:
Entry and exit section codes needs to check certain properties before allowing the access and removal of access to a particular code segment.
These conditions are:
1. Bounded waiting.
2. Mutual exclusion.
3. checking thread execution status to allows other threads to enter the critical section (CS).
Answer:
import java.util.Scanner;
public class HollowSquare
{
public static void main(String args[])
{
Scanner scan = new Scanner(System.in);
int size;
System.out.print("Enter the size : ");
size = scan.nextInt();
if(size>=1 && size<=20)
{
for(int i=0; i<size; i++)
{
for(int j=0; j<size; j++)
{
if(i==0 || j==0 || i==size-1 || j==size-1)
System.out.print("*");
else
System.out.print(" ");
}
System.out.println();
}
}
else
System.out.println("Invalid size.");
}
}