Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
The diff you're trying to view is too large. We only load the first 3000 changed files.
94 changes: 82 additions & 12 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,12 @@ Aşağıdakileri yap:

İPUCU: fonksiyon oluşturmaya gerek yok
*/

let surucuYasi=17;
if(surucuYasi>18){
console.log(true )
}else{
console.log(false)
}
/*
Görev 1b - Değerler (puanlamaya dahil değildir)

Expand All @@ -31,7 +36,12 @@ Aşağıdakileri yap:

İPUCU: fonksiyon oluşturmaya gerek yok
*/

let birinciDeger = "elma"
let ikinciDegeri = "armut"
if ( birinciDeger != ikinciDegeri){
birinciDeger = "muz"
}
console.log(birinciDeger)
/*
Görev 1c - String bir değeri Number'a dönüştürün (puanlamaya dahil değildir)

Expand All @@ -42,7 +52,9 @@ Aşağıdakileri yap:

İPUCU: Number metoduna bakabilirsin
*/

let deger1 = "1999"
let sayidegeri = Number (deger1);
console.log(sayidegeri)
/*
Görev 1d - Çarpma

Expand All @@ -52,9 +64,11 @@ Aşağıdakileri yaparak carpma isimli fonksiyonu tamamla:
3. console.log(carpma(7,4)) ile yazdığın fonsiyonu test edin. Console'da sonucu 28 olarak görmelisin.
*/

function carpma(/*buraya kodunu yazabilirsin*/) {
/*buraya kodunu yazabilirsin*/
function carpma(a,b) {
let sonuc = a*b ;
return sonuc
}
console.log(carpma (3,5))

/* Görev 2 : Köpeğin Yaşı */

Expand All @@ -65,9 +79,11 @@ Aşağıdakileri yap:
3. Hesaplanan köpeğin yaşını dönün.
*/

function kopeginYasi(/*buraya kodunu yazabilirsin*/) {
/*buraya kodunu yazabilirsin*/
function kopeginYasi(yas) {
let sonuc = yas * 7;
return sonuc;
}
console.log(kopeginYasi(5))

/* Görev 3 */
/*
Expand All @@ -84,7 +100,16 @@ OYUNUN KURALLARI: Makas Kağıdı yener| Kağıt Taşı yener | Taş Makas'ı ye
*/

function oyun(oyuncu, bilgisayar) {
/*buraya kodunu yazabilirsin*/
if ((oyuncu == "Makas" && bilgisayar=="Kağıt") ||
(oyuncu == "Kağıt" && bilgisayar == "Taş") ||
(oyuncu == "Taş" && bilgisayar == "Makas")) {

return "Kazandın!"
} else if (oyuncu == bilgisayar){
return "Beraberlik"
}
else {
return "Kaybettin!"}
}

// Şimdi Taş, Kağıt, Makas oyununu bilgisayara karşı oynayalım!
Expand All @@ -102,6 +127,26 @@ function oyun(oyuncu, bilgisayar) {
Şimdi kendi seçtiğin bir seçime karşı bilgisayarın rastgele oluşturduğu seçimi yukarıda yazdığın oyun fonsiyonu ile oynayın ve sonucu console'a yazdırın.
Örn: console.log(oyun("Makas",bilgisayarinSecimi()))
*/
function bilgisayarinSecimi (){
Math.random()*3;
let secim = Math.floor(Math.random()*3);

if(secim == 0){

return "Makas"

}
else if(secim == 1){

return "Kagıt"

}
else if (secim == 2){
return "Tas"
}

}
console.log (oyun("Makas", bilgisayarinSecimi()));

/* Görev 4 : Metrik Dönüştürücü */

Expand Down Expand Up @@ -144,10 +189,18 @@ Aşağıdakileri cocukSarkisi fonksiyonunda yap:
4. Bu döngüde, her seferinde cocukSarkisi fonsiyonu çalışsın ve console.log'a dönen metni yazdırsın.
*/

function cocukSarkisi(/*buraya kodunu yazabilirsin*/) {
/*buraya kodunu yazabilirsin*/
function cocukSarkisi(sayi) {

let metin= sayi + "küçük maymun yatakta zıplamış, biri düşüp başını çarpmış, Anne doktoru aramış, Doktor çok kızmış: Bir daha yatakta zıplamak yok!"

return metin;

}
console.log(cocukSarkisi(5));

for(let i=5; i>=1; i--){
console.log(cocukSarkisi(i));
}
/* Görev 6 : Not Hesaplayıcı */

/*
Expand All @@ -163,8 +216,25 @@ Aşağdakileri notHesapla fonksiyonunda yap.
dönün
*/

function notHesapla(/*buraya kodunu yazabilirsin*/) {
/*buraya kodunu yazabilirsin*/
function notHesapla(sonuc)
{
if(sonuc >=90){
return "A aldın"
}
else if (sonuc>=80) {
return "B aldın"
}
else if (sonuc>=70) {
return "C aldın"
}
else if (sonuc>=60) {
return "D aldın"
}
else if (sonuc>=60) {
return "F aldın"
}
console.log(notHesapla(70))

}

/* Bonus Çalışma: Sesli harf sayacı - Kaç tane sesli harf var? */
Expand Down
12 changes: 12 additions & 0 deletions node_modules/.bin/acorn

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

17 changes: 17 additions & 0 deletions node_modules/.bin/acorn.cmd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

28 changes: 28 additions & 0 deletions node_modules/.bin/acorn.ps1

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

12 changes: 12 additions & 0 deletions node_modules/.bin/browserslist

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

17 changes: 17 additions & 0 deletions node_modules/.bin/browserslist.cmd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

28 changes: 28 additions & 0 deletions node_modules/.bin/browserslist.ps1

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

12 changes: 12 additions & 0 deletions node_modules/.bin/escodegen

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

17 changes: 17 additions & 0 deletions node_modules/.bin/escodegen.cmd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

28 changes: 28 additions & 0 deletions node_modules/.bin/escodegen.ps1

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

12 changes: 12 additions & 0 deletions node_modules/.bin/esgenerate

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

17 changes: 17 additions & 0 deletions node_modules/.bin/esgenerate.cmd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading