Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 899206c

Browse files
author
İSMAİL TAŞDELEN
committed
master
1 parent 83a1ad1 commit 899206c

File tree

3 files changed

+39
-2
lines changed

3 files changed

+39
-2
lines changed

.gitignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,4 +50,5 @@
5050
/app/Java_Project_61/nbproject/private/
5151
/app/Java_Project_61/build/
5252
/app/Java_Project_62/nbproject/private/
53-
/app/Java_Project_63/nbproject/private/
53+
/app/Java_Project_63/nbproject/private/
54+
/app/Java_Project_63/build/

app/Java_Project_62/src/java_project_62/Java_Project_62.java

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
* and open the template in the editor.
55
*/
66
package java_project_62;
7+
import java.util.Scanner;
78

89
/**
910
*
@@ -14,8 +15,25 @@ public class Java_Project_62 {
1415
/**
1516
* @param args the command line arguments
1617
*/
18+
public static void polinom()
19+
{
20+
Scanner tara = new Scanner(System.in);
21+
System.out.println("A değerini giriniz : ");
22+
int a = tara.nextInt();
23+
System.out.println("B değerini giriniz : ");
24+
int b = tara.nextInt();
25+
System.out.println("C değerini giriniz : ");
26+
int c = tara.nextInt();
27+
System.out.println("D değerini giriniz : ");
28+
int d = tara.nextInt();
29+
System.out.println("X değerini giriniz : ");
30+
int x = tara.nextInt();
31+
double polinom = a + (b*x) + c*Math.pow((double)x, 2)+d*Math.pow((double)x, 3);
32+
System.out.println("Sonuç : " + polinom);
33+
}
1734
public static void main(String[] args) {
1835
// TODO code application logic here
36+
polinom();
1937
}
2038

2139
}

app/Java_Project_63/src/java_project_63/Java_Project_63.java

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,26 @@ public class Java_Project_63 {
1414
/**
1515
* @param args the command line arguments
1616
*/
17+
public static int topla(int x, int y)
18+
{
19+
int t = x + y;
20+
return t;
21+
}
22+
public static int topla(int x, int y, int z)
23+
{
24+
int t = x + y + z;
25+
return t;
26+
}
27+
public static double topla(double x, double y)
28+
{
29+
double t = x + y;
30+
return t;
31+
}
1732
public static void main(String[] args) {
18-
// TODO code application logic here
33+
// TODO code application logic here
34+
System.out.println(topla(2,3));
35+
System.out.println(topla(2.3,3.6));
36+
System.out.println(topla(1,2,3));
1937
}
2038

2139
}

0 commit comments

Comments
 (0)