Go: package main

import (
	"bufio"
	"os"
	"strings"
	"strconv"
	"fmt"
)

func main() {
	scanner := bufio.NewScanner(os.Stdin)
	d := 0
	e := 0
	for scanner.Scan() {
		info := strings.Split(scanner.Text(), ",")
		a, _ := strconv.Atoi(info[0])
		b, _ := strconv.Atoi(info[1])
		c, _ := strconv.Atoi(info[2])
		if a*a + b*b == c*c {
			d++
		}
		if a == b {
			e++
		}
	}
	fmt.Println(d)
	fmt.Println(e)
}

Python: hisi=0
tyou=0
while True:
    try:
        a,b,c=map(int,input().split(","))
        if a**2+b**2==c**2:
            tyou +=1
        elif a==b:
            hisi +=1
    except:
        print(tyou)
        print(hisi)
        break

Python: n1 = n2 = 0
while True:
    try:
        a, b, c = map(int, line.split(','))
        if a**2 + b**2 == c**2:
            n1 += 1
        elif a == b:
            n2 += 1
    except EOFError: break
print(n1)
print(n2)

Python: import sys
n0=n1=0
for l in sys.stdin:
    a,b,c=map(int,l.split(","))
    if a*a+b*b-c*c==0:
        n0+=1
    elif a==b:
        n1+=1
print(n0)
print(n1)

Python: r1 = r2 = 0
try:
    while 1:
        a, b, c = map(int, input().split(','))
        if a ** 2 + b ** 2 == c ** 2:
            r1 += 1
        elif a == b:
            r2 += 1
except:
    pass

print(r1)
print(r2)

Python: ans = [0, 0]
while  True:
    try:
        a, b, c = map(int, input().split(','))
    except:
        break
    if a**2 + b**2 == c**2:
        ans[0] += 1
    if a == b:
        ans[1] += 1
print(*ans, sep="\n")

Python: import sys
r=d=0
for e in sys.stdin:
 a,b,c=map(int,e.split(','))
 if a*a+b*b==c*c:r+=1
 if a==b:d+=1
print(f'{r}\n{d}')

Python: rectangle=0
lozenge=0
while True:
	try:
		x,y,z=map(int, input().split(","))
		if x==y:
			lozenge+=1
		elif x**2+y**2==z**2:
			rectangle+=1
	except EOFError:
		break
print(rectangle)
print(lozenge)

Python: import sys

rhombus = rectangle = 0
for line in sys.stdin:
    a, b, c = map(int, line.split(","))
    if c ** 2 == a ** 2 + b ** 2:
        rectangle += 1
    if a == b and c ** 2 != a ** 2 + b ** 2:
        rhombus += 1
print(rectangle, rhombus)

Python: square=0
rhombus=0
while 1:
    try:
        a,b,c=map(int,input().split(","))
        if a==b:rhombus+=1
        elif a**2+b**2==c**2:square+=1
    except:break
print(square)
print(rhombus)

Python: cnt1 = 0
cnt2 = 0
try:
    while(True):
        a, b, c = map(int, input().split(","))
        if a**2 + b**2 == c**2:
            cnt1+=1
        if a==b:
            cnt2+=1
except:
    print(cnt1)
    print(cnt2)

Python: r = 0
l = 0
while True:
    try:
        a, b, c = map(int, input().split(','))
        if a == b:
            l += 1
        else:
            if a**2 + b**2 == c**2:
                r += 1
    except:
        print(r)
        print(l)
        break

Python: rectangle = 0
parallelogram = 0

while True:
    try:
        a,b,d = (int(x) for x in input().split(","))
        if d * d == (a * a) + (b * b):
            rectangle += 1
        elif a == b:
            parallelogram += 1
    except EOFError:
        break
print(rectangle)
print(parallelogram)

Python: import sys

rhombus = rectangle = 0
for line in sys.stdin:
    a, b, c = map(int, line.split(","))
    if c ** 2 == a ** 2 + b ** 2:
        rectangle += 1
    elif a == b:
        rhombus += 1
print(rectangle)
print(rhombus)

Python: # AOJ 0032 Plastic Board
# Python3 2018.6.15 bal4u

rect = loz = 0
while True:
	try:
		a, b, c = list(map(int, input().split(',')))
	except EOFError:
		break
		
	if a*a + b*b == c*c:
		rect += 1
	elif a == b and a + b > c and b + c > a:
		loz += 1
print(rect, loz, sep='\n')

Python: hisi=0
tyou=0
while True:
    try:
        a,b,c=map(int,input().split(","))
        if a**2+b**2==c**2:
            tyou +=1
        elif a==b:
            hisi +=1
    except:
        print(tyou)
        print(hisi)

Python: 
if __name__ == '__main__':

	x = y = 0

	while True:

		try:
			a,b,c = map(int,input().split(","))

			if a*a + b*b == c*c:
				x += 1
			elif a == b:
				y += 1

		except EOFError:
			break

	print(x)
	print(y)

Python: import sys

rhombus = rectangle = 0
for line in sys.stdin:
    a, b, c = map(int, input().split(","))
    if c ** 2 == a ** 2 + b ** 2:
        rectangle += 1
    if a == b and c ** 2 != a ** 2 + b ** 2:
        rhombus += 1
print(rectangle, rhombus)

Python: rect_cnt = dia_cnt = 0

while True:
  try:
    a, b, c = map(int, input().split(","))
    
    rect_cnt += (a ** 2 + b ** 2 ==  c ** 2)
    dia_cnt += (a == b)

  except EOFError:
    break

print(rect_cnt)
print(dia_cnt)

Python: A = 0
B = 0
while True:    
    try:
        a,b,c = map(int,input().split(","))
    except:
        break

    if a**2 + b**2 == c**2:
        A += 1
    elif a==b:
        B += 1
    
print(A)
print(B)

Python: s=0
h=0
while True:
  try:
    a,b,c =map(int,input().split(","))
  except:break
   
  if a**2+b**2==c**2:
    s = s+1
  elif a==b:
    h = h+1
    
print(s)
print(h)

Python: import sys
r=d=0
for e in sys.stdin:
 a,b,c=map(int,e.split(','))
 if a*a+b*b==c*c:r+=1
 if a==b:d+=1
print(r)
print(d)

Python: rec, loz = 0, 0
while True:
    try:
        a, b, c = map(int, input().split(','))
    except:
        break
    if a == b:
        loz += 1
    elif a ** 2 + b ** 2 == c ** 2:
        rec += 1
print(rec)
print(loz)

Python: import sys
j = []
for line in sys.stdin:
    a, b, c = line.split(",")
    j += [int(a)**2 + int(b)**2 - int(c)**2]
print(len([i for i in j if not i]))
print(len([i for i in j if i]))

Python: s = 0
t = 0
while 1:
    try:
        a,b,c = map(int,input().split(","))
        if a**2 + b**2 == c**2:
            s += 1
        elif a == b  :
            t += 1

    except EOFError:
        print(s)
        print(t)
        break

Python: cho = 0
hishi = 0
while True:
    try:
        a, b, c = map(int, input().split(','))
    except:
        break
    if a**2 + b**2 == c**2 and a!=b:
        cho += 1
    elif a**2 + b**2 != c**2 and a==b:
        hishi += 1
print(cho)
print(hishi)

Python: import sys


# ???????????????????§???¢?????§???
# https://ja.wikipedia.org/wiki/????§???¢
def is_rectangle(a, b, c):
    """ ????????¢?????§???
        4??????????§??????¨???90???
    """
    return a**2 + b**2 == c**2


def is_rhombus(a, b, c):
    """ ????????¢?????§???
        ??¨???????????????????????????????????????
    """
    return a==b


if __name__ == '__main__':
    rectangle_count = 0  # ???????????§???????????¢?????°
    rhombus_count = 0  # ???????????§???????????¢?????°

    # ??????????????\???
    for line in sys.stdin:
        a, b, c = [int(x) for x in line.strip().split(',')]

        # ????????¢???????????¢???????????????
        if is_rectangle(a, b, c):
            rectangle_count += 1
        if is_rhombus(a, b, c):
            rhombus_count += 1
    
    # ????????????????????????
    print('{0}\n{1}'.format(rectangle_count, rhombus_count))

Python: X = 0
Y = 0
while True :
  try :
    a, b, c = map(int, input().split(","))
    if(c ** 2 == a ** 2 + b ** 2) :
      X += 1
    elif(a == b) :
      Y += 1
    else :
      pass
  except :
    print(X)
    print(Y)
    break

Python: import sys
j = [int(a)**2 + int(b)**2 - int(c)**2 for line in sys.stdin for a,b,c in line.split(",")]
print(len([i for i in j if not i]))
print(len([i for i in j if i]))

Python: rect_num = 0
diam_num = 0

while True:
    try:
        a,b,c = map(int, input().split(','))
        if a**2 + b**2 == c**2:
            rect_num += 1
        elif a == b:
            diam_num += 1
    except EOFError:
        break

print(rect_num)
print(diam_num)

Python: import sys

t = 0
h = 0
for line in sys.stdin :
    line = list(map(int, line.split(',')))
    if line[2]**2 == line[0] ** 2 + line[1] ** 2 :
        t += 1
    else :
        h += 1
print(t)
print(h)

Python: import sys
rect = 0
loze = 0
for line in sys.stdin:
    s = line.split(',')
    a,b,c = int(s[0]),int(s[1]),int(s[2])
    if a**2 + b**2 == c**2:
        rect += 1
    if a == b and a+b > c:
        loze += 1
print(rect)
print(loze)