import java.util.Scanner ;
class Ex1 {
private float [ ] [ ] notes = new float [ 3 ] [ 4 ] ;
float result;
Scanner sc
= new Scanner
( System .
in ) ;
private void PobierzImieOdUsera( ) {
System .
out .
print ( "Podaj imię ucznia: " ) ; name = sc.next ( ) ;
}
private void PobierzPrzedmiotyIocene( ) {
for ( int i = 0 ; i < subjects.length ; i++ ) {
System .
out .
print ( "Podaj nazwy przedmiotów, których uczy się " + name
+ ": \n " ) ; subjects[ i] = sc.next ( ) ;
for ( int j = 0 ; j < subjects[ i] .length ( ) ; j++ ) {
System .
out .
print ( "Podaj ocenę dla przedmiotu " + subjects
[ i
] + ": \n " ) ; notes[ i] [ j] = sc.nextFloat ( ) ;
}
}
}
private void SrednieOcen( ) {
}
public static void main
( String [ ] args
) { Ex1 n = new Ex1( ) ;
n.PobierzImieOdUsera ( ) ;
n.PobierzPrzedmiotyIocene ( ) ;
n.SrednieOcen ( ) ;
}
}
aW1wb3J0IGphdmEudXRpbC5TY2FubmVyOwoKY2xhc3MgRXgxIHsKICAgIHByaXZhdGUgU3RyaW5nIG5hbWU7CiAgICBwcml2YXRlIFN0cmluZ1tdIHN1YmplY3RzID0gbmV3IFN0cmluZ1szXTsKICAgIHByaXZhdGUgZmxvYXRbXVtdIG5vdGVzID0gbmV3IGZsb2F0WzNdWzRdOwogICAgZmxvYXQgcmVzdWx0OwogICAgU2Nhbm5lciBzYyA9IG5ldyBTY2FubmVyKFN5c3RlbS5pbik7CgogICAgcHJpdmF0ZSB2b2lkIFBvYmllcnpJbWllT2RVc2VyYSgpIHsKICAgICAgICBTeXN0ZW0ub3V0LnByaW50KCJQb2RhaiBpbWnEmSB1Y3puaWE6ICIpOwogICAgICAgIG5hbWUgPSBzYy5uZXh0KCk7CiAgICB9CgogICAgcHJpdmF0ZSB2b2lkIFBvYmllcnpQcnplZG1pb3R5SW9jZW5lKCkgewogICAgICAgIGZvciAoaW50IGkgPSAwOyBpIDwgc3ViamVjdHMubGVuZ3RoOyBpKyspIHsKICA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