QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#71360#5270. Easily Distinguishable Trianglesneko_nyaa#AC ✓21ms4432kbC++201.1kb2023-01-09 20:44:112023-01-09 20:44:12

Judging History

你现在查看的是最新测评结果

  • [2023-08-10 23:21:45]
  • System Update: QOJ starts to keep a history of the judgings of all the submissions.
  • [2023-01-09 20:44:12]
  • 评测
  • 测评结果:AC
  • 用时:21ms
  • 内存:4432kb
  • [2023-01-09 20:44:11]
  • 提交

answer

#include <bits/stdc++.h>
using namespace std;

#define int long long
const int M = 998244353;

signed main() {
	ios::sync_with_stdio(0); cin.tie(0);
	
	int n; cin >> n;
	vector<string> s(n);
	for (int i = 0; i < n; i++) {
		cin >> s[i];
	}

	int ans = 1;
	for (int i = 0; i < n; i++) {
		for (int j = 0; j < n; j++) {
			if (s[i][j] == '?') {
				int l = j, r = j;
				while (r < n && s[i][r] == '?') {
					r++;
				}
				r--;

				int bd = 2;
				if (l > 0 && s[i][l-1] == '#') bd--; 
				if (r+1 < n && s[i][r+1] == '#') bd--;
				
				if (bd == 2) {
					ans = (ans*(r-l+2)) % M;
				} else {
					ans = (ans*bd) % M;
				}

				j = r;
			}
		}
	}

	for (int i = 0; i < n; i++) {
		for (int j = 0; j < n; j++) {
			if (s[j][i] == '?') {
				int l = j, r = j;
				while (r < n && s[r][i] == '?') {
					r++;
				}
				r--;

				int bd = 2;
				if (l > 0 && s[l-1][i] == '#') bd--; 
				if (r+1 < n && s[r+1][i] == '#') bd--;
				
				if (bd == 2) {
					ans = (ans*(r-l+2)) % M;
				} else {
					ans = (ans*bd) % M;
				}

				j = r;
			}
		}
	}
	cout << ans << '\n';

	return 0;
}

Details

Tip: Click on the bar to expand more detailed information

Test #1:

score: 100
Accepted
time: 1ms
memory: 3328kb

input:

2
.?
?#

output:

4

result:

ok 1 number(s): "4"

Test #2:

score: 0
Accepted
time: 1ms
memory: 3376kb

input:

3
#??
#??
?##

output:

1

result:

ok 1 number(s): "1"

Test #3:

score: 0
Accepted
time: 1ms
memory: 3368kb

input:

3
.#.
#?#
.#.

output:

0

result:

ok 1 number(s): "0"

Test #4:

score: 0
Accepted
time: 2ms
memory: 3288kb

input:

1
.

output:

1

result:

ok 1 number(s): "1"

Test #5:

score: 0
Accepted
time: 2ms
memory: 3288kb

input:

1
#

output:

1

result:

ok 1 number(s): "1"

Test #6:

score: 0
Accepted
time: 2ms
memory: 3400kb

input:

1
?

output:

4

result:

ok 1 number(s): "4"

Test #7:

score: 0
Accepted
time: 2ms
memory: 3452kb

input:

2
?.
?.

output:

12

result:

ok 1 number(s): "12"

Test #8:

score: 0
Accepted
time: 2ms
memory: 3284kb

input:

3
?.?
.#?
?.?

output:

256

result:

ok 1 number(s): "256"

Test #9:

score: 0
Accepted
time: 2ms
memory: 3460kb

input:

5
?????
.?.#.
???#?
?##??
?.?.?

output:

12288

result:

ok 1 number(s): "12288"

Test #10:

score: 0
Accepted
time: 2ms
memory: 3368kb

input:

10
...###???.
?.???.??#.
??.?????..
.#..?.????
???...?..?
.???.?..??
??.????.??
.????.?.??
#.????.?#?
?.##???#??

output:

0

result:

ok 1 number(s): "0"

Test #11:

score: 0
Accepted
time: 1ms
memory: 3372kb

input:

10
..?.??????
.?.?.?.?..
???#????.?
??#.??.??.
?..???.?#.
.????.?.??
?...?.#???
?.?..???.?
?.?..??.??
###..#.??#

output:

453983775

result:

ok 1 number(s): "453983775"

Test #12:

score: 0
Accepted
time: 2ms
memory: 3304kb

input:

100
.........?...........................................?...?.....?...................#??..??......?...
......?....................................?...?..?...?...?..??......?...?#......?............?.?.?.
.....??........??............?........?..............?...?..?.............................?......

output:

882086962

result:

ok 1 number(s): "882086962"

Test #13:

score: 0
Accepted
time: 21ms
memory: 4336kb

input:

1000
?..???.?.......?.????.??.???.....??.????.??.??.?.?..??.?....?.??.?.??..?.?.?.?..??...?.?.???..?.#..??...?.??..????..???...??.....??.???.?.???.??.??.?....???.?????...?????..?..?..??.?.?.?...?.?????....?..?.??..??....??.?.??....?..?.??...???..??...?.???????..?....?.?.???..??.?..???..?..????.?.???...

output:

74184164

result:

ok 1 number(s): "74184164"

Test #14:

score: 0
Accepted
time: 3ms
memory: 4288kb

input:

1000
..........................................................................................................................................................................................................................................................................................................

output:

1

result:

ok 1 number(s): "1"

Test #15:

score: 0
Accepted
time: 3ms
memory: 4300kb

input:

1000
#######################################################################################################################################################################################################################################################################################################...

output:

1

result:

ok 1 number(s): "1"

Test #16:

score: 0
Accepted
time: 3ms
memory: 4336kb

input:

1000
???????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????...

output:

219193901

result:

ok 1 number(s): "219193901"

Test #17:

score: 0
Accepted
time: 4ms
memory: 4260kb

input:

1000
.#####.###..##...#....#####..#.#.##.#...#.##.......#.###########.###..#.##..#..#######.####....#.....#.##.....#....###....#####..##.#####.#.#####.#.#.#..#.##.#.#.##..##.##.#...#....####.#####.#.#.##.#####.##.#.##..##.#.#######....##...##..#.###.#..#..##..#.#...###.#..#...#.#...###......#.#...##...

output:

1

result:

ok 1 number(s): "1"

Test #18:

score: 0
Accepted
time: 17ms
memory: 4372kb

input:

1000
#?#?##?####?#??#???##??##?#?##?###?###????###?????###?#?###?##?####?##?#?#???###???#??##???###?###?#?##?##??#?##?###???##????#####???#####?#???#####?#?#?#??#?#???#???#??#######???#?#??###?##?????#????###?##???????##???###?#???##???#?######??#?#??#????##??###??###?#######?##?#???##?##???#??##?##...

output:

0

result:

ok 1 number(s): "0"

Test #19:

score: 0
Accepted
time: 15ms
memory: 4424kb

input:

1000
??.???.??..???....?...?..???.??.?...??.?.?.?....?....???.????.?..?.???..???.?.???....?...?.?.?.????.?...?..?.?.?...??.?..??.?.?.?.?..???.??..???????????..???...?...?..?..?.???...?.?.??..?.?..?..????...??.??...?..??....?.???....???.??...??...?.....??..??...??...??..?...??...??..???....??.....?.?...

output:

411081010

result:

ok 1 number(s): "411081010"

Test #20:

score: 0
Accepted
time: 7ms
memory: 4348kb

input:

1000
???????????.???????????????.?.????????????.???????????????????????.???.???????????????..??.???????????????????????.??????.??????.????.???.??????????.????????????????.????.????????????????????.?????????????.?.??????????????????????.?????????????????????????????????????.???????????.?????????.????...

output:

283085945

result:

ok 1 number(s): "283085945"

Test #21:

score: 0
Accepted
time: 3ms
memory: 4412kb

input:

1000
??????????????.?????????????.??????????????????????????????????????????????????????????????????????????????????????????.????.??????????????????????????????????????.???????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????...

output:

845505829

result:

ok 1 number(s): "845505829"

Test #22:

score: 0
Accepted
time: 4ms
memory: 4288kb

input:

1000
???????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????...

output:

290495287

result:

ok 1 number(s): "290495287"

Test #23:

score: 0
Accepted
time: 7ms
memory: 4420kb

input:

1000
???????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????...

output:

329366395

result:

ok 1 number(s): "329366395"

Test #24:

score: 0
Accepted
time: 6ms
memory: 4420kb

input:

1000
???????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????...

output:

148797428

result:

ok 1 number(s): "148797428"

Test #25:

score: 0
Accepted
time: 4ms
memory: 3928kb

input:

653
????.?.?.????.?????..?????#???????.?????#???.?.??????.??????.???????.???#???..?????#?????.???.?.???.???????.????.???????#.??????##???.??#.?.??.????????.????????#??????.???.????????#?.??.#???.?????????????##????????.??.?#??.??????????????????###???????.#??????????.#????.?.?????.??????????????????...

output:

333100622

result:

ok 1 number(s): "333100622"

Test #26:

score: 0
Accepted
time: 13ms
memory: 4336kb

input:

1000
#??.????#?????????????????????????.#?????????????.???.???????.????#.?????????.????#??.?????????##?????????????????????.????.?.??????.????#??.???#??.#????..?????????????????#???????..??.?????###???.?????????????#???????.?#?.??##..???????.#?.?.??.?????????????.??????????.?.?#??.?#?.???????#.?????...

output:

783725733

result:

ok 1 number(s): "783725733"

Test #27:

score: 0
Accepted
time: 4ms
memory: 3612kb

input:

373
.????..#.?#???.???.?????????#?.??#?.??????????.????#???..?#.??#?.???.??????????#???????.?.?.??.??????.?.?????#???.????..???.?????????.??#??.#??????.??.##..??.??????#???.???.?#???????..????????.?????????.???.##?.???#???.??##???????????????????.#????.?#?????????????????????????.?.??.???.?.????????...

output:

663414612

result:

ok 1 number(s): "663414612"

Test #28:

score: 0
Accepted
time: 16ms
memory: 4404kb

input:

1000
###?...#.?#.?#..?#??.#???.?????.??????#???????????.#.?.?.?.?????????????.?.?..???#??.????#????.???????????.??#???????.???.?.???#?.???.???##?.?#.#????.??.???.??????.??.?..???#?.##.?.?.#.?.??#???????????????.???#.?.??????.??????##.??????????#.???.?.#?.??????.#.?.??????????#????.#?.?????????????.?...

output:

580221572

result:

ok 1 number(s): "580221572"

Test #29:

score: 0
Accepted
time: 4ms
memory: 3584kb

input:

501
#.?.??.#.??..?.??????.??#??..??.???#?..??#????.?#.?????##.????.###.??#???.??????????###.?#?????.?..??.#????.???.?.???.?????#.?#.????..##.????..???#.???#????..????#.?.???#.??#?.??.?.??#????.?..?#?.#.##.??????.?????.?.????..??#??.#..?#.?????##?.##..?????#?.#??????.?#?..???????#.??..????????#??????...

output:

932879967

result:

ok 1 number(s): "932879967"

Test #30:

score: 0
Accepted
time: 18ms
memory: 4408kb

input:

1000
#.?????#.?#?.??..???.??????#??.??.?.?.#???.?????###??.?##??..??#.???.?????##.?#??.????#??.??#....?###??????.##.#.#??..?..??.?#??.?#?.????#???.#?.??????##??.????.????.??.????.????.?.?##.??.???.??.???.#??.??##.??##??.?#???????..#..????????##?.?#?.#.????.???#..#.???#????.?#.?#??..???#??.?#????????...

output:

105267212

result:

ok 1 number(s): "105267212"

Test #31:

score: 0
Accepted
time: 9ms
memory: 3708kb

input:

629
??#?..#.#.?.?.?.##.?#.#???.??##?.?##?.?..?????##?.##.?#####.#??.??..??##?.???#.?.#..#?.###???..????.?#?..##?..?.#?.###.?.??#????.#..??###.???.????.?.?###.?###?.??????.?.????.???#?????.?.#.?###?.??#.?###?.???.??.##.??????.??.???##.?.?.?###?...?.?.?#??.???##?.#.??#??...#.??####.?.??.?.#?.???.#.?#....

output:

352165579

result:

ok 1 number(s): "352165579"

Test #32:

score: 0
Accepted
time: 19ms
memory: 4408kb

input:

1000
.?#?.??#??.?.#?.?#?.??.#??.?.#####.#?.##..??.???#???.??..????.?#..#???..?#?..??##???..??????#.?#.???...##?..?#?..?#.??.?.##.?..???.??.?#.#.???..#??...??##.?..??.#.?#.#.?.????.????##.#.???.??#??.#???.??????.?.??#??.???#???.??.?##???.#????????.??.?##??.??#?.?.#?.??##.##?.?.??#?.#?.#??...??#????.....

output:

791485202

result:

ok 1 number(s): "791485202"

Test #33:

score: 0
Accepted
time: 1ms
memory: 3460kb

input:

309
????.??????????.#.????#.??#??.??.???.???#???..???#???..?.?#..?.???????.??.??.?????????.#???????.???.??..????#?.?.?.???????.?.???.??.???.??????.???#?.?????..?.??#?.????.??????????..?#??.?.?.????.?.??????.?????#???????????????..???.##???..?.??.?.?.??????#??????.?.????.??#???..???#???.??????..???.?...

output:

147352727

result:

ok 1 number(s): "147352727"

Test #34:

score: 0
Accepted
time: 11ms
memory: 4424kb

input:

1000
??????#???????.#?.?????...??...???????.????????#???.??.???.??.???##.??..?.???#??.??....?????.?.?.?????????##...???..?#...???.???????##?????.?.#??????????????????????.?????.?.??????.????#.#?.??.?.??.???#..?????#????..?.?????#.??#?.??.??#..?.????.?#.?????.???#????.??????#?.??##..?..?????.?#??..??...

output:

237888114

result:

ok 1 number(s): "237888114"

Test #35:

score: 0
Accepted
time: 5ms
memory: 3584kb

input:

437
#..??????????.???#.?.??#.??.??..??.?##..?#..#.?#...????...??????.?.????..#??.?..?.???#.#??????????????????..##.????#??.?##.??##?????.????#??????.??#?.#?.#???.?#????.??....#?.??..?.##??.??.????.????..#?.#..?.#????..?...??.?..?.???#??.#?????..??.?#.???????.???.?.##?..??.???.?.??????#?.???##???.??....

output:

635064633

result:

ok 1 number(s): "635064633"

Test #36:

score: 0
Accepted
time: 14ms
memory: 4336kb

input:

1000
?##??.??#???.#?????.??.#.??.?.????..??#?...???##..???#.?.###???.????.????#??..##?.?.??#??.??#?????.??.?.?????.????.?#..?#?.?##?.?##?????.?.#??..??..??#??..##???.?????#?.##?.??????###??????????.#???...?.????.???#.#.?#...??????#?.?.?.?.?#.?.###?...????.?.??.?.??..#??.##.??.?.?#..????...???????###...

output:

167395452

result:

ok 1 number(s): "167395452"

Test #37:

score: 0
Accepted
time: 13ms
memory: 4240kb

input:

861
.##??.###?..?#??.#?.?.?.?.??#????.??#.??#..??.?.??#..??#..?.????###.?.?..????#?.???.#?.?.????.?#####.?..?#??.????.??#.??...???..?.?.??#?????.#.?.???##???.......??#..#.????.?##.###.?##?.#?.?.#?.????#?.???.#.#.??????.?.##.??#?..???#???.#?..?#.??.?.??#.?###????..?##????.??????..?###.?..?#.?#?.?????...

output:

608860292

result:

ok 1 number(s): "608860292"

Test #38:

score: 0
Accepted
time: 18ms
memory: 4288kb

input:

1000
?.?..?.?#?.#.???#????.??#??..??#.?#?.?..????#?.#????.??#.#?.??#???????.?#???..???####????.???.?##.?##.??#?.?..#??.?????.?#??.???#???.?.?.?##??.???.?.?#????????.?..##.??.??..?....??.??????.???.????.##??.#????.??.????#??....??????..?????#?.?##.###??.?####.#?..?#??.#.???.?##??.#.?#.?.???#.?.####?....

output:

542489178

result:

ok 1 number(s): "542489178"

Test #39:

score: 0
Accepted
time: 3ms
memory: 3432kb

input:

285
.?##.?##.##..??.?#####?.####....?.#?.#.#.?#.????#??????.#?.?.?#.??#.????#??.?##?.????..?#??.?..?#??..?#..?##..?...##..#.?..##???.?????#.?#?.?#??.?.??##???.....???..??.?...?##??.?..###??.####?.?##.?.?.#.?.#.?..?..###??.##??.?#.???.#.##...??.?.###?.??##.?.?##???.#.#.?.?#.??...#?..??##?.
?#..#??.?....

output:

245977859

result:

ok 1 number(s): "245977859"

Test #40:

score: 0
Accepted
time: 21ms
memory: 4336kb

input:

1000
??##??.?.?....#??.?#.???##????.????#.?.?.#?.??.#?.##?.?##..?###??..?...##?.##.?#.#.#.#.#??.??.#??..??.?.???.#??..??.#?.?????.##?.????##.???#....?#..#.#.?##.#.#.?#.?#....##??.#??..###?.??#.?##??.#?.##????.?.?.?##.###?.??##?.?#.??..?#.#?.???#???.#.?.??#?.#.?#..##.?###???.##...#.?..#?..?##?.#.?###...

output:

60167919

result:

ok 1 number(s): "60167919"

Test #41:

score: 0
Accepted
time: 6ms
memory: 3716kb

input:

477
??#?..???.#??.?.?.?.?.???.#...#??.????.?#?...???.?.#??.?.?.?????????????#???.?????..?#???????..?????..??????.??..?.??.??.???????..?#??????...?...??.?.?.???????.??????##?.???...#?...?.?.?..???#?..?.....?..???#.?..??#.??...??????.##?..?#..?.?#.#.????....##?.?..?#????????.??#.???#?????.??#???.????....

output:

374654830

result:

ok 1 number(s): "374654830"

Test #42:

score: 0
Accepted
time: 21ms
memory: 4432kb

input:

1000
.?....?.?#?.?.???.#??.????????...???.#.???#.?#???.??.#.??##??.???#...?..#?.??..?.?.??.##??.??????#?.?.????????#..??.?.?#?.?#?.##?.???..?????.?.??#.??..?.???.?#?.??.?.????##?????.???...?.?.??????#.#?..??..?..#..??????.???.??.??.?#???..?##..?.#??.???...?..#?..?##.???????#?.??.?.?#?.??.??.?#..#......

output:

539027202

result:

ok 1 number(s): "539027202"

Test #43:

score: 0
Accepted
time: 9ms
memory: 3696kb

input:

605
#.?#??????.#.????..##?.??.???.???#....?#?..?#?.???#?.?...#?.#??...#.?#.??.??..#.??#..????????.??#..?#...?##?.?#???...?..????##..?#??.??.?.#.?#?..?#?..###?.???#.??..#??.??.?#.#???..????.?#..?.?...?..?#....?#?.??????????##??.?.??..?.??##.?.#..?...????.?.?.?.?.????.?.?...????????.??#?..??#.?.??###?...

output:

237663713

result:

ok 1 number(s): "237663713"

Test #44:

score: 0
Accepted
time: 16ms
memory: 4312kb

input:

1000
.##.?##.##?.#?.???#..?.??#?.###????.##.......?????#.??.?.#?...#?.????.?..?.?..?##.??.??.?#.????.?.#?.#??.?...?????..#?.??.?.???.?.????#?????.#..##.#.?....#???.#?..???.??.???#.#?...??#.?.???.?#...#.?.??#???.?????#.?.??#?..###.?.????#???..??.#.??..?#.?#.??.??.?.???#.#?..?..?.??.?..?##??????..?.?....

output:

98816482

result:

ok 1 number(s): "98816482"

Test #45:

score: 0
Accepted
time: 3ms
memory: 3384kb

input:

325
.#?.?.?????.??..#.??.?.?##.#??.#.?#..#.?.??#.###.#?.???..?#??.######...#?.??.#..?#.?#.??#??.??...#.##.?..?.#...??#??.?.#????..?.???.?.#.??##.#.#...?..?#..?.??.????..##.#.?#..?#?.?##.??#.?#..??#?.#.#?.???.....#..#..??#.?#.#..??.#.???.##?.?##??.##?.??#.?#..??.#.#?..?.??????#.?#??.#..??#.#??.#??.?....

output:

406888362

result:

ok 1 number(s): "406888362"

Test #46:

score: 0
Accepted
time: 20ms
memory: 4428kb

input:

1000
..?##??.###?...?#.#?.#..?.?#?.?.?.?###.????.??..#..###?..#.?.?.?#????.#.?.#?..?.?#?..?.#...??.##..?..?..???.??#??..??.?.??#.###?.?.?##.?.?###?.?#...#..?.?.#.?##?..?.??##?.##..?.##.###.###?...?.??#??.??#.??????##??......?#?.#?.#??...?.?#..?##?.?.#.?.?.??...?.??#?..#...??#..?.?.??.?.?.##??..?##.....

output:

343712117

result:

ok 1 number(s): "343712117"

Test #47:

score: 0
Accepted
time: 5ms
memory: 3636kb

input:

453
...#.#?.?.#..###?.#.?##?.#.?#.?.#??....#.#???.#.?...#.?##..#.#.#?..?..?#.#?.???#.##.?.??#?...?#?.??.?#.#..???#..##?.?.##.#???.#?..??#.###..?#.?#?.?.#.##?..?.?##.?#.??.?..#.??#?.###?.?##...?#..?##..##.?#..#.#...?.?.?#...?###..?.#.?#..#.????###.#..??###???.?##.?...######.#.?.?.#.???#.####.????##.#...

output:

566128872

result:

ok 1 number(s): "566128872"

Test #48:

score: 0
Accepted
time: 18ms
memory: 4432kb

input:

1000
..#?....####.#?.?###?.?.????#..?##..#?.#.###.?#..#.#..?#####.#.##..?#..??#??...??#..####...?...??..???.?#?.?.???.???##?..#.....##.#??.###.?.#.?.#.#?.?....??#?.###...#....#...#.????#.#?.#.#.?#.?.#.???##...??#.?.##.??.#.#.?..?#?.??#.?.??.??..?#??..##.#?.##?.#.##....##.?#.#....?.##?.?.###.?#?.?##....

output:

316920556

result:

ok 1 number(s): "316920556"

Test #49:

score: 0
Accepted
time: 2ms
memory: 3432kb

input:

134
???.#?.?..????..????..???..?#?.?.?.??#??..??...??.??.?#...?#??.???#????.?..#...?#.?????????.?.#?.??????.?...?.?....#....?#...?.?.???..
?#.????..??.????.??..???????????..#??...?.?.?.?#.#??...?..???.?.?.#?...#?.?.?..#.?..???#?.#..????.??.....??.?..?#??..?#.????#?..#?..?.
?#??..??.????..??...?.?......

output:

580715970

result:

ok 1 number(s): "580715970"

Test #50:

score: 0
Accepted
time: 14ms
memory: 4348kb

input:

1000
??.??.?#????...??#.?##?.?.??#????...?...??.?...?.?..?...?.?....??...?..??.???.?.????..?..?.???#??..#??...?.?.??..??.??????.???..?.?.????...???.?....???????....??..??.?#????...?.??.????.??.?.?.???.?..???.#???..??.?...??.??#..?.??.....??..?#?..??.....????..?...?.........#?.?..?.#??.?????.?#????.?...

output:

246110752

result:

ok 1 number(s): "246110752"

Test #51:

score: 0
Accepted
time: 1ms
memory: 3408kb

input:

262
#..??..?..###..?.?#??.??..?#..?...???#.#..?..?....?.??...?#?.#.?......?..?.?.#???..?..???.?.???#...#???.???????.?...?#?......#..???...??..??..???.??.?#?.??.?.????###??.??.??#.?.....#.#..##?.?#..?.?#?...?.?.?.#..??..???.?..???..???##.##.?#..???.?..?.#????.#??.#?.
..?##?.?.?#???.?...?????.##...?.....

output:

464019932

result:

ok 1 number(s): "464019932"

Test #52:

score: 0
Accepted
time: 20ms
memory: 4428kb

input:

1000
###?.#.#???..?#.??..?.#??.?.??.##..??..?..???#.?..?#.#.?.#.??#.#???.?.?#?.??..??..#???...#.?....#.#?.?#???????..#.#..#...#.??.??.#...???#.???......?.#?.?.?.?#.?#...?..??...?...?????.?#..#?.???....?.#??????.?#.#??.??#??????..#???...?#.?#.#?..?##.?.?..?.#??.....??#..?#??...????.#?.?.#..?.???#..??...

output:

547740315

result:

ok 1 number(s): "547740315"

Test #53:

score: 0
Accepted
time: 2ms
memory: 3556kb

input:

390
.#.#.?.?.?..?##......??.?....#.?...#?..?#?.?#?..?..?.?.....#?...#..?.?#.#?.?.?..??....?.#.?.?#..?##.??.#..#.?.##.?.#??.?....#.?#..?#?....#?.?..??.#.??...#.#?.?#.?....#.##.??###.??#?.....?#?..?#..?###...?.?.....##.?#.??..#..#....??.?.##..?..##?...??#..#.?#.#.??##.#.?.#?....###..?#...##..?.?##..#?...

output:

842588007

result:

ok 1 number(s): "842588007"

Test #54:

score: 0
Accepted
time: 18ms
memory: 4272kb

input:

1000
#.????#.###.....##.?.?.?.??#.##?.......#.?.?#??.?#???.??.###.?..????.#..#?.?....#..?#.#.#.#?...?.??...#.#?..###.###??..?#.????##.?#.##???..?.#.?.?###.???..?#?.?.#.?.?#####???.##..#??.#...?.#...#..#.##.?#.?##??.?.?..?.#?.?..#..??....?#?.....##.#..##.#??..?#.....##.#.?#.?#....#..#?...?.#??.#.#..?...

output:

983088081

result:

ok 1 number(s): "983088081"

Test #55:

score: 0
Accepted
time: 5ms
memory: 4024kb

input:

814
..#....#.?..#?.#..##.#..#.##.?##.###..##.#.###.?.?##?..#.#?...?.##..##.?#.....?#.?.??##.#..?.###?..?.??......?#?.#?.#.?.??...##?.#?.###...#...??#..#.?#.?.#..#?...#.?..???###?..#..###...?.#.##.??.##?...#...?#.?....##.#.#.?...#.#.#.#..##??.##..####...?#.?#?.#.##.#.##.?.#.#.#.##..#?.#?.##...#.##.?....

output:

693226393

result:

ok 1 number(s): "693226393"

Test #56:

score: 0
Accepted
time: 11ms
memory: 4316kb

input:

1000
#.#.#.?####..?##??.#.#?...#?.#.#?.?#.#...#.?.??##.#.#.?###?........?##?...#?..#.?#.?.##.#.#.#.?..?###.##.?#.?#..?#.?..?.#?.?##.##.?....#.##?.??..?#.?.?#?..#??.?.#.#.#......###?..#.?#........##.??...?.##..?...??###..?.#.#.#?.?#?.#.#...?#?.##?....##......##??...?.?.??....#..??#...####.?..?##...??...

output:

519222055

result:

ok 1 number(s): "519222055"