participant-id,category,timestamp,prompt,answer,stimulus-id,previous-delay,stimulus_time 201,3,174143187.639525,Write a statement that toggles the value of the bool variable onOffSwitch. That is, if onOffSwitch is false, itsvalue is changed to true; if onOffSwitch is true, its value is changed to false.,onOffSwitch = !onOffSwitch;,1,15871.341206835346,60000 participant-id,category,timestamp,prompt,answer,stimulus-id,previous-delay,stimulus_time 201,3,174209912.133848,Write the definition of a function isPositive, that receives an integer parameter and returns true if the parameter is positive, and false otherwise.,int isPositive(int a) { return (a > 0); },2,6691.764055404556,60000 participant-id,category,timestamp,prompt,answer,stimulus-id,previous-delay,stimulus_time 201,3,174274586.721647,Clunker Motors Inc. is recalling all vehicles in its Extravagant line from model years 1999-2002. Given an int variable modelYear and a string modelName, print "RECALL" if modelYear and modelName match the recal details,if (modelYear >= 1999 ## modwlYeat <= 20),0,4650.273405475142,60000 201,3,174337180.459294,Implement a function containsDuplicate that accepts a vector of integers and returns true if it contains a duplicate element, and false otherwise,bool containsDyu[;ocate] (vector a){ for (int i = 0l) },6,2561.5472330438515,60000 participant-id,category,timestamp,prompt,answer,stimulus-id,previous-delay,stimulus_time 201,3,174403116.128223,Given a string, s, and an integer, x, update s such that its characters are shifted by x. Ex. s = "cd", x = 1. Loop results in s = "de",for (i = 0; i < s.length(); i_{ } ,4,5910.270259511187,60000 201,3,174468319.293106,Given integer variables amount and total both initialized to 0, write a loop that reads in values for amount from standard in and adds them to total until total is greater than 100.,while 1 cin >> amount; total += amount; if total >=100) break;,5,5174.159119834031,60000 participant-id,category,timestamp,prompt,answer,stimulus-id,previous-delay,stimulus_time 201,3,174532100.850048,Implement a function is_sorted that accepts a vector of integer values and returns true if it is non-decreasing, and false otherwise,bool is_sorted(vector) { for int i; i { for ... if vector[i] > max },7,6191.319535001296,60000 participant-id,category,timestamp,prompt,answer,stimulus-id,previous-delay,stimulus_time 201,3,174662540.532855,Implement a function countdown() that accepts an integer n as a parameter and counts down from n, printing each number to standard output, separated by a space. After reaching n, print "liftoff!",void countdown(int n) { for i=0 cout << i << endl; cout << "liftoff!" },8,4204.78117090889,60000