F.A.Q
Hand In Hand
Online Acmers
Problem Archive
Realtime Judge Status
Authors Ranklist
 
     C/C++/Java Exams     
ACM Steps
Go to Job
Contest LiveCast
ICPC@China
Best Coder beta
VIP | STD Contests
    DIY | Web-DIY beta
Author ID 
Password 
 Register new ID

View Compilation Error

0_0_16207507_1372.cpp:1:1: error: stray '\302' in program
 N bulbs  Accepts: 275  Submissions: 1237 Time Limit: 10000/5000 MS (Java/Others)  Memory Limit: 65536/65536 K (Java/Others)Problem DescriptionN bulbs are in a row from left to right,some are on, and some are off.The first bulb is the most left one. And the last one is the most right one.they are numbered from 1 to n,from left to right.in order to save electricity, you should turn off all the lights, but you're lazy. coincidentally,a passing bear children paper(bear children paper means the naughty boy), who want to pass here from the first light bulb to the last one and leave.he starts from the first light and just can get to the adjacent one at one step. But after all,the bear children paper is just a bear children paper. after leaving a light bulb to the next one, he must touch the switch, which will change the status of the light.your task is answer whether it's possible or not to finishing turning off all the lights, and make bear children paper also reach the last light bulb and then leave at the same time.InputThe first line of the input file contains an integer T, which indicates the number of test cases.For each test case, there are 2 lines.The first line of each test case contains 1 integers n.In the following line contains a 01 sequence, 0 means off and 1 means on.1 \leq T \leq 101≤T≤101 \leq N \leq 10000001≤N≤1000000OutputThere should be exactly T lines in the output file.The i-th line should only contain "YES" or "NO" to answer if it's possible to finish.Sample Input1
 ^
0_0_16207507_1372.cpp:1:1: error: stray '\240' in program
0_0_16207507_1372.cpp:1:1: error: stray '\302' in program
0_0_16207507_1372.cpp:1:1: error: stray '\240' in program
0_0_16207507_1372.cpp:1:1: error: stray '\302' in program
0_0_16207507_1372.cpp:1:1: error: stray '\240' in program
0_0_16207507_1372.cpp:1:1: error: stray '\302' in program
0_0_16207507_1372.cpp:1:1: error: stray '\240' in program
0_0_16207507_1372.cpp:1:1: error: stray '\302' in program
0_0_16207507_1372.cpp:1:1: error: stray '\240' in program
0_0_16207507_1372.cpp:1:1: error: stray '\302' in program
0_0_16207507_1372.cpp:1:1: error: stray '\240' in program
0_0_16207507_1372.cpp:1:1: error: stray '\302' in program
0_0_16207507_1372.cpp:1:1: error: stray '\240' in program
0_0_16207507_1372.cpp:1:1: error: stray '\' in program
0_0_16207507_1372.cpp:1:1: error: stray '\' in program
0_0_16207507_1372.cpp:1:1: error: stray '\342' in program
0_0_16207507_1372.cpp:1:1: error: stray '\211' in program
0_0_16207507_1372.cpp:1:1: error: stray '\244' in program
0_0_16207507_1372.cpp:1:1: error: stray '\342' in program
0_0_16207507_1372.cpp:1:1: error: stray '\211' in program
0_0_16207507_1372.cpp:1:1: error: stray '\244' in program
0_0_16207507_1372.cpp:1:1: error: stray '\' in program
0_0_16207507_1372.cpp:1:1: error: stray '\' in program
0_0_16207507_1372.cpp:1:1: error: stray '\342' in program
0_0_16207507_1372.cpp:1:1: error: stray '\211' in program
0_0_16207507_1372.cpp:1:1: error: stray '\244' in program
0_0_16207507_1372.cpp:1:1: error: stray '\342' in program
0_0_16207507_1372.cpp:1:1: error: stray '\211' in program
0_0_16207507_1372.cpp:1:1: error: stray '\244' in program
0_0_16207507_1372.cpp:1:1: error: missing terminating ' character
0_0_16207507_1372.cpp:5:1: error: missing terminating ' character
 HintChild's path is: 123234545
 ^
0_0_16207507_1372.cpp:1:1: error: 'N' does not name a type
 N bulbs  Accepts: 275  Submissions: 1237 Time Limit: 10000/5000 MS (Java/Others)  Memory Limit: 65536/65536 K (Java/Others)Problem DescriptionN bulbs are in a row from left to right,some are on, and some are off.The first bulb is the most left one. And the last one is the most right one.they are numbered from 1 to n,from left to right.in order to save electricity, you should turn off all the lights, but you're lazy. coincidentally,a passing bear children paper(bear children paper means the naughty boy), who want to pass here from the first light bulb to the last one and leave.he starts from the first light and just can get to the adjacent one at one step. But after all,the bear children paper is just a bear children paper. after leaving a light bulb to the next one, he must touch the switch, which will change the status of the light.your task is answer whether it's possible or not to finishing turning off all the lights, and make bear children paper also reach the last light bulb and then leave at the same time.InputThe first line of the input file contains an integer T, which indicates the number of test cases.For each test case, there are 2 lines.The first line of each test case contains 1 integers n.In the following line contains a 01 sequence, 0 means off and 1 means on.1 \leq T \leq 101≤T≤101 \leq N \leq 10000001≤N≤1000000OutputThere should be exactly T lines in the output file.The i-th line should only contain "YES" or "NO" to answer if it's possible to finish.Sample Input1
 ^


Hangzhou Dianzi University Online Judge 3.0
Copyright © 2005-2024 HDU ACM Team. All Rights Reserved.
Designer & Developer : Wang Rongtao LinLe GaoJie GanLu
Total 0.000000(s) query 1, Server time : 2024-11-17 02:50:30, Gzip enabled