Python

Pythonの変数名

Pythonでちょっとつまづいたのでメモ。 Javaとかだと class sample{ static int f(int x){ return x*2; } public static void main(String[] args) { int f = 3; System.out.println(f(5)); } } で10と出力される。メソッド名と変数名がかぶっても良い。 し…