Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

1. Which of the following is true of the arguments to strcat(s1, s2);? More than

ID: 3531603 • Letter: 1

Question

1. Which of the following is true of the arguments to strcat(s1, s2);? More than one answer may be correct so make sure to select all of the answers that apply.<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />

a. both s1 and s2 must be valid strings

b.only s2 must be a valid string

c. s1 must have room to contain the result

d. only s2 must be a valid string and s1 must have room to contain the result

2.The strcmp function returns ____. More than one answer may be correct so make sure to select all of the answers that apply.

a. 0 if the two strings are equal

b. a negative value if the first argument is alphabetically less than the second

c. a positive value if the first argument is alphabetically greater than the second

d. nothing

Explanation / Answer

b.only s2 must be a valid string



c. a positive value if the first argument is alphabetically greater than the second

a. 0 if the two strings are equal