-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcounters.java
More file actions
83 lines (69 loc) · 1.5 KB
/
Copy pathcounters.java
File metadata and controls
83 lines (69 loc) · 1.5 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
package week04;
public class temp3
{
static int counter = 0;
int unstatic_counter = 0;
public static void main(String[] args)
{
int duygu = murat(5);
murat(5);
arsan();
int a = arsan();
}
public static void arsan()
{
System.out.println("aslkdjaksjdlkasdklam");
}
public static int murat(int hand1)
{
System.out.println("kjashdkjas");
return 50;
}
}
package week04;
import java.util.Random;
import java.util.Scanner;
public class temp4
{
public static void main(String[] args)
{
temp3.arsan();
temp1.m2(4, 5);
/*Scanner sc = new Scanner(System.in);
int a = sc.nextInt();
Scanner.nextInt();
Random r = new Random();
a = r.nextInt(500);
Random.nextDouble();
double d = Math.pow(2, 5);*/
System.out.println(Math.pow(2, 5));
/*m1();
temp4.m1();
temp4 t = new temp4();
t.m1();*/
System.out.println(temp3.counter);
temp3.counter++; //duygu
temp3.counter++; // murat
temp3.counter++; // arsan
System.out.println("visitors in total:" + temp3.counter);
temp3 duygu = new temp3();
duygu.unstatic_counter++;
temp3 arsan = new temp3();
arsan.unstatic_counter++;
int a = 5;
System.out.println(a); // 5
a++; //6
++a; // 7
System.out.println(a); // 7
System.out.println(a++); // see 7, but it is 8
System.out.println(a); // 8
System.out.println(++a); // see 9, it is actually 9
System.out.println(a); // 9
int b = a++; // b=9, a = 10
System.out.println("a:" + a + " b:" + b);
b = ++a; // a:11, b: 11
}
public void m1()
{
}
}