Go: package main

import (
	"fmt"
	"sort"
)

// TriangleKind kind of triangle
type TriangleKind int

const (
	// Nothing not triangle
	Nothing TriangleKind = iota
	// RightTriangle the right triangle
	RightTriangle
	// SharpTriangle the sharp triangle
	SharpTriangle
	// ObtuseTriangle the obtuse triangle
	ObtuseTriangle
) // const for Triangle kind

type result struct {
	rTriangle int
	sTriangle int
	oTriangle int
}

func (res *result) String() string {
	return fmt.Sprintf("%d %d %d %d", res.rTriangle+res.sTriangle+res.oTriangle, res.rTriangle, res.sTriangle, res.oTriangle)
}

func checkTriangleType(a int, b int, c int) TriangleKind {
	p := []int{a, b, c}
	sort.Sort(sort.IntSlice(p))
	if !(p[0]+p[1] > p[2] && p[1]+p[2] > p[0] && p[2]+p[0] > p[1]) {
		return Nothing
	}

	c = (p[0] * p[0]) + (p[1] * p[1]) - (p[2] * p[2])
	if c == 0 {
		return RightTriangle
	}
	if c > 0 {
		return SharpTriangle
	}
	return ObtuseTriangle
}

func main() {
	var res = new(result)
	var a, b, c int
	var hasNext = true
	for hasNext {
		fmt.Scanf("%d %d %d", &a, &b, &c)
		switch checkTriangleType(a, b, c) {
		case Nothing:
			hasNext = false
		case RightTriangle:
			res.rTriangle++
		case SharpTriangle:
			res.sTriangle++
		case ObtuseTriangle:
			res.oTriangle++
		}
	}
	fmt.Println(res.String())
}

Python: f = True
cnt = 0
l = [0,0,0]
while f:
    t = [int(s) for s in input().split()]
    t.sort()
    if t[0]+t[1] <= t[2]:
        f = False
        break
    if t[0]**2+t[1]**2 > t[2]**2:
        l[0]+=1
    elif t[0]**2+t[1]**2 == t[2]**2:
        l[1]+=1
    else:
        l[2]+=1
print(sum(l),l[1],l[0],l[2])

Python: import sys
ans = [0, 0, 0, 0]
for a, b, c in (sorted(map(int, l.split())) for l in sys.stdin.readlines()):
    if a+b <= c:
        print(*ans)
        exit()
    n, m = a**2+b**2, c**2
    ans[0] += 1
    if n == m:
        ans[1] += 1
    elif n > m:
        ans[2] += 1
    else:
        ans[3] += 1

Python: import sys
import fileinput
import math
from collections import Counter
from decimal import Decimal

RADIAN180 = Decimal(math.pi)
ANGLE90 = 90

counter = Counter()


def is_triangle(edges):
    return edge[0] + edge[1] > edge[2] and \
           edge[1] + edge[2] > edge[0] and \
           edge[2] + edge[0] > edge[1]


def calculate_radian(edges):
    edge.sort()
    radian = []

    s = sum(edge) / 2
    s = Decimal(math.sqrt(s * (s - edge[0]) * (s - edge[1]) * (s - edge[2])))
    h = 2 * s / edge[2]

    radian.append(Decimal(math.asin(h / edge[0])))
    radian.append(Decimal(math.asin(h / edge[1])))

    radian.append(RADIAN180 - sum(radian))

    return radian


for input_list in fileinput.input():

    edge = [Decimal(item) for item in input_list.split(" ")]

    if is_triangle(edge):

        counter["ALL"] = counter["ALL"] + 1

        radian = calculate_radian(edge)

        max_radian = max(radian)
        max_angle = math.degrees(max_radian)

        if max_angle < ANGLE90:
            counter["ACUTE"] += 1
        elif max_angle == ANGLE90:
            counter["RIGHT"] += 1
        else:
            counter["OBTUSE"] += 1
    else:
        for garbage in sys.stdin:
            pass
        break

print(counter['ALL'], counter["RIGHT"], counter["ACUTE"], counter["OBTUSE"])

Python: result = [0] * 3
while 1:
    a = input()
#print(sum(result), *result)

Python: result = [0] * 3
while 1:
    a = input()
#print(sum(result), *result)

Python: f = True
cnt = 0
l = [0,0,0]
while f:
    t = [int(s) for s in input().split()]
    t.sort()
    if t[0]+t[1] <= t[2]:
        f = False
        continue
    if t[0]**2+t[1]**2 > t[2]**2:
        l[0]+=1
    elif t[0]**2+t[1]**2 == t[2]**2:
        l[1]+=1
    else:
        l[2]+=1
print(sum(l),l[0],l[1],l[2])

Python: countTri = 0
countTriCho = 0
countTriSma = 0
countTriLar = 0
while(True):
    hens = list(map(int, input().split()))
    MAX = max(hens)
    hens.remove(MAX)
    SUM = 0
    for hen in hens:
        SUM += hen
    if MAX >= SUM:
        print(countTri, countTriCho, countTriSma, countTriLar)
        break
    else:
        countTri+=1
        SUM_2 = 0
        for hen in hens:
            SUM_2 += (hen**2)
        MAX_2 = (MAX ** 2)
        if (MAX_2 == SUM_2):
            countTriCho+=1
        elif (MAX_2 < SUM_2):
            countTriSma+=1
        else:
            countTriLar+=1

Python: #input_f = "3 4 5\n2 1 2\n6 3 4\n1 1 1\n1 2 3"
def t_check(a,b,c):
    if a + b > c:
        if b + c > a:
            if a + c > b: return True
    return False



def f_check(a_, b_, c_):
    tmp = []
    tmp.append(a_)
    tmp.append(b_)
    tmp.append(c_)
    sqrts = []
    for i in range(3):
        sqrts.append(tmp[i]**2)
    m = max(sqrts)
    s = sum(sqrts)

    print(m,s)

    if m == (s - m): return(0)
    if m > (s - m): return(2)
    if m < (s - m): return(1)
    
    
counter=[0,0,0]
    
    
while(1):
    input_f = input()


    t = input_f.split("\n")[i].split()
    fn, sn, tn = int(t[0]),int(t[1]),int(t[2])
    if t_check(fn,sn,tn):
        counter[f_check(fn,sn,tn)] += 1
    else: break
    

print(sum(counter),counter[0], counter[1], counter[2])

Python: # -*- coding: utf-8 -*-
import sys
from math import sqrt


def calc_triangle_type(edge_length_str):
    edge_length = edge_length_str.split(" ")
    edge_length = list(map(lambda x: int(x), edge_length))
    edge_length_sorted = sorted(edge_length)
    if edge_length_sorted[0] + edge_length_sorted[1] <= edge_length_sorted[2]:
        return None
    right_angled_longest_edge = sqrt(
        edge_length_sorted[0] * edge_length_sorted[0] + edge_length_sorted[1] * edge_length_sorted[1])
    if edge_length_sorted[2] < right_angled_longest_edge:
        return 0
    elif edge_length_sorted[2] == right_angled_longest_edge:
        return 1
    else:
        return 2


def main():
    inputStr = sys.stdin.read()
    lines = inputStr.split("\n")
    counts_by_tryangle_type = {0: 0, 1: 0, 2: 0}
    total_triangle = 0
    for line in lines[:-1]:
        tryangle_type = calc_triangle_type(line)
        if tryangle_type is None:
            continue
        counts_by_tryangle_type[tryangle_type] = counts_by_tryangle_type[tryangle_type] + 1
        total_triangle = total_triangle + 1
    print("{} {} {} {}".format(total_triangle,
                               counts_by_tryangle_type[1],
                               counts_by_tryangle_type[0],
                               counts_by_tryangle_type[2]))


if __name__ == '__main__':
    main()

Python: def run():
    judge = [0, 0, 0, 0]
    while True:
        a, b, c = (int(x) for x in sorted(input().split()))
        if a + b <= c or min([a, b, c]) <= 0:
            print(' '.join(map(str, judge)))
            break
        else:
            S = a ** 2 + b ** 2 - c ** 2
            judge[0] += 1
            if S == 0:
                judge[1] += 1
            elif S > 0:
                judge[2] += 1
            else:
                judge[3] += 1





if __name__ == '__main__':
    run()

Python: eikaku = 0
tyokkaku = 0
donnkaku = 0
checker = True
while checker:
    tl = sorted(list(map(int, input().split()))) # tl= triangle_list
    if tl[0] + tl[1] - tl[2] > 0:
        criterion = tl[0]**2 + tl[1]**2 - tl[2]**2
        if criterion > 0:
            eikaku += 1
        elif criterion == 0:
            tyokkaku += 1
        else:
            donnkaku += 1
    else:
        print(eikaku+tyokkaku+donnkaku, tyokkaku, eikaku, donnkaku)
        checker = False

Python: import sys

c0 = c1 = c2 = c3 = 0

for x in sys.stdin:
    a,b,c  = map(int,x.split())
    L = [a,b,c]
    L.sort()

    if L[2] < L[0] + L[1]:
        c0 += 1
        if L[2]**2 == L[0]**2 + L[1]**2:
            c1 += 1
        elif L[2]**2 < L[0]**2 + L[1]**2:
            c2 += 1
        elif  L[2]**2 > L[0]**2 + L[1]**2:
            c3 += 1
    else:
        break
print(c0,c1,c2,c3)