We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6b2fb74 commit 8c4d813Copy full SHA for 8c4d813
codeforces_day01/team.go
@@ -0,0 +1,35 @@
1
+package main
2
+
3
+import (
4
+ "bufio"
5
+ "fmt"
6
+ "os"
7
+ "strconv"
8
+ "strings"
9
+ // "strings"
10
+)
11
12
13
+func main() {
14
+ scanner:=bufio.NewScanner(os.Stdin)
15
+ // scanner.Split(bufio.ScanWords)
16
+ scanner.Scan()
17
+ t,_:=strconv.Atoi(scanner.Text())
18
+ count:=0;
19
+ for t>0{
20
+ scanner.Scan();
21
22
+ line:=strings.Split(scanner.Text(), " ")
23
24
+ if(line[0]=="1" &&line[1]=="1"){
25
+ count=count+1;
26
+ }else if(line[0]=="1"&&line[2]=="1"){
27
28
+ }else if(line[1]=="1"&&line[2]=="1"){
29
+ count=count+1
30
+ }
31
32
+ t--;
33
34
+ fmt.Println(count)
35
+}
0 commit comments