-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathffl.cpp
54 lines (48 loc) · 998 Bytes
/
ffl.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
//
// ffl.cpp
// codechef
//
// Created by Tanishq Chamola on 25/04/20.
// Copyright © 2020 Tanishq Chamola. All rights reserved.
//
#include <iostream>
using namespace std;
/*
int main()
{
int t;
cin>>t;
while(t--)
{
int n,s;
cin>>n>>s;
int arr[n],type[n];
for (int i=0; i<n; i++) {
cin>>arr[i];
}
for (int i=0; i<n; i++) {
cin>>type[i];
}
int defender=200, forward=200;
for (int i=0; i<n; i++) {
if (type[i]==0) {
if (arr[i]<defender) {
defender=arr[i];
}
}
if (type[i]==1) {
if (arr[i]<forward) {
forward=arr[i];
}
}
}
if ((defender+forward) <= (100-s)) {
cout<<"yes\n";
}
else{
cout<<"no\n";
}
}
return 0;
}
*/