Answer:
#include <iostream>
using namespace std;
int main()
{
int cookies;
cin >> cookies;
cout << "The calorie consumption is: " << cookies * 142 << endl;
return 0;
}
Explanation:
First line: include basic library of C++(input and output).
using namespace std;
Says to compiler we are using std.
int main() Main function
int cookies, cookies variable, of int type
cin >> cookies
get the number of the cookies from user
cout Print the text and calories(one cookie have 142 calories)
Have a nice day ;)
Answer:
def insSort(arr):
ct=0;
for i in range(1, len(arr)):
key = arr[i]
j = i-1
while j >=0 and key < arr[j] :
arr[j+1] = arr[j]
j -= 1
ct=ct+1;
arr[j+1] = key
return arr,ct;
print(insSort([2,1]))
Output of the program is also attached.
Answer:
The correct option is Option B
Explanation:
We need to find examples of client-side code.
Client Side code: The part of code, that doesn't require server for performing specific task
SO, The correct option is Option B
Prompt for special characters in user name
Reason: We can use alert to generate prompt using JavaScript or through validation and it can be done on client side.
All other options, we need to hit the server to perform the task, So they are not client-side code.
Answer:
The NEA’s focus on building new performing arts centers led to an increased production of arts.