Which of the following checks if the sixth character of a string variable named myMail is the @ sign using a Boolean variable named atSign set to true if this is true?

a.
```
for (k = 0; k < myMail.length; k++)
{
if(myMail.charAt(k) == @)
atSign = true;
}
```

b.
```
atSign = "@";
for (k = 0; k < 7; k++)
{
if(myMail.charAt(k) == atSign)
flag = true;
}
```

c.
```
if(myMail.substr(5, 1) == "@")
```

d.
```
if(myMail.substr(1, 5) == "@")
atSign = true;
```


c.
```
if(myMail.substr(5, 1) == "@")
```

Computer Science & Information Technology

You might also like to view...

Critical Thinking QuestionsCase 2-2Anna is a competitive runner. She wants to improve her performance and decides to keep track of data for six months to determine if the time of day or year she runs affects her performance. Her worksheet contains the following data: start and end time, total time, and distance.Now Anna wants to know the longest total time she has run. By looking at the total time values, she finds the longest total time to be 54 minutes. Instead of manually entering that value in a cell below the total time data, Anna decides to use the MAX function to determine the longest total time. Why did Anna prefer to use the MAX function?

a.She believes that 54 minutes is her best running time.c.She believes that 54 minutes is not her best running time.b.The MAX function recalculates the highest value each time a new value is entered into the worksheet.d.The MAX function provides a constant value that will not change for this cell when a new value is entered into the worksheet. What will be an ideal response?

Computer Science & Information Technology

Some inkjet printers offer a(n) _____ so that a user does not have to refill the ink so often

Fill in the blank(s) with correct word

Computer Science & Information Technology

Which is not a primary color system?

a. R, G, B b. R, Y, B c. V, M, Y, K d. C, M, Y, K

Computer Science & Information Technology

A ____ is a technologically skilled person who uses his or her skills to obtain unauthorized entry into computers.

A. ?zombie B. ?cracker C. ?script kiddie D. ?whacker

Computer Science & Information Technology