SCUSA Region ACM Balloon Logo ICPC Masthead
2010 ACM ICPC South Central USA Regional Programming Contest

A - Let's All Go to the Movies

Thibodeaux is the biggest fan of Arthur Conan Mysterio's series of detective novels. He has read each of them as soon as they were published, and had tried to get his friend Boudreau to read them as well. But Boudreau has a penchant against reading, so he has waited for the all movies to come out. And finally, this fall, the last movie in the series is being released. So Boudreau is planning to watch all of the movies in a row.

Thibodeaux, however, reminded him that Mysterio has done an amazing job at putting surprising plot twists and clues in each of the stories. So Boudreau realizes that after he watches each of the movies once, he should watch it a second time so that, now knowing who the villains are, he can spot the clues.

But the situation is even more complicated than that. Mysterio was very clever with his novels, and put clues in the earlier books to the cases in the the later ones. This means that Boudreau is going to, after watching each movie, go back and watch each of the previous movies in the series and then re-watch the current movie.

Boudreau realizes that this may take a lot of time, so he wants your help to figure out how long he will spend watching all these movies. He knows how long each of the movies is, and he has Thibodeaux around to instantaneously take out each movie and put in the next movie to watch. But it's up to you to figure out the total amount of time spent watching the movies.

Input

The input will begin with a line containing a single positive integer D indicating the number of data sets. There will then be D lines, each containing one data set. Each data set will start with a positive integer M (1 ≤ M ≤ 1000) indicating the number of movies in the series (Mysterio was quite a prolific writer). Then M positive integers will follow, representing the number of minutes. The ordering of these numbers will be the same as the order in which the movies were released. Each movie will be at most 200 minutes long.

Output

For each data set in the input, output a single line containing the phrase:

Boudreau is going to spend T minutes watching movies.

where T is the amount of time Boudreau is going to spend watching movies.

Sample Input

3
1 1
2 1 10
3 11 22 33

Sample Output

Boudreau is going to spend 2 minutes watching movies.
Boudreau is going to spend 23 minutes watching movies.
Boudreau is going to spend 176 minutes watching movies.