Submission #1054565

#TimeUTC-0UsernameProblemLanguageResultExecution timeMemory
10545652024-08-12 10:43:59kititnikJoker (BOI20_joker)C++14
0 / 100
0 ms348 KiB
#include <bits/stdc++.h>
using namespace std;
const int MAXN = 10;
bool used[MAXN];
int cntrs[MAXN];
int graph[MAXN][MAXN];
bool ans = false;
bool is_checking(int l, int r, int street)
{
return (street <= r && street >= l);
}
void dfs(int v, int p, int counter, int n, int l, int r)
{
used[v] = true;
cntrs[v] = counter;
for(int i = 0; i < MAXN; i++)
{
if(i==v) continue;
if(i==p) continue;
int street = graph[v][i];
if(street == 0) continue;
if(is_checking(l, r, street)) continue;
if(used[i])
{
int distance = abs(counter - cntrs[i])+1;
 
הההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההה
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

Compilation message (stderr)

Joker.cpp: In function 'int main()':
Joker.cpp:52:30: warning: 'memset' used with length equal to number of elements without multiplication by element size [-Wmemset-elt-size]
   52 |         memset(cntrs, 0, MAXN);
      |                              ^
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...