Swif Fonksiyonlar kullanımı , Genel kod yapısı

in #utopian-io7 years ago (edited)

Selamlar, bugün yeni bir konuya merhaba diyoruz. Yeni konumuz fonksiyonlar. 2 Ders ten oluşacak. 2 derside bugün çekip yayınlayacağım. Discord dan arkadaşın isteği üzerine bu konuyu uzun uzun anlattım . Güzel yorumlarınız için teşekkür ederim . İyi seyirler , iyi dersler .

Greetings, we say hello to a new topic today. Newly positioned functions. It will consist of 2 lessons. I will shoot and publish 2 lessons today. I told this topic for a long time at the request of your friend from Discord. Thank you for your nice comments. Good looking, good lessons.



Projemizin Kodları
(Project Code)




import UIKit

**// Fonksiyonlar**

**//Basit fonksiyon tanımı**

func fonksiyonismi(){

    

    print("Merhaba")

}

**//Sayısal işlem yapan fonksiyon**

func hesapla(){

    

    let a = 2

    let b = 3

    

    print(a*b)

}

**//Çarpma İşlemi yapan fonksiyon**

func carpma(a:Int,b:Int)->Int{

    

    return a*b

}

**// String değer alıp intger sonuç dönen fonksiyon**

func kacKarakterli(yazi:String)->Int{

    return yazi.count // Swift 4 versiyonudur

    // return yazi.characters.count

}

//kacKarakterli(yazi: "TürkçeSwift4ProgramlamaEğitimineHoşgeldiniz")

func selamlama(isim:String)->String{

    

    return "Merhaba \(isim)"

}

selamlama(isim: "Ali")




  • Video ya ingilizce çeviri yapana " 1 SBD " Ödül verilecektir

  • The person who makes video or english translation will be awarded "1 SBD".


Videoma ingilizce çeviri yapabilirsiniz
English subtitles can be added to the video.

Kodlara github adresimden'de ulaşabilirsiniz
You can access the code file from my "Githup" account

Önceki derslerimiz / Previous lessons.**





Posted on Utopian.io - Rewarding Open Source Contributors

Sort:  

Thank you for the contribution. It has been approved.

You can contact us on Discord.
[utopian-moderator]

Hey @kerimcaglar I am @utopian-io. I have just upvoted you!

Achievements

  • You have less than 500 followers. Just gave you a gift to help you succeed!
  • Seems like you contribute quite often. AMAZING!

Community-Driven Witness!

I am the first and only Steem Community-Driven Witness. Participate on Discord. Lets GROW TOGETHER!

mooncryption-utopian-witness-gif

Up-vote this comment to grow my power and help Open Source contributions like this one. Want to chat? Join me on Discord https://discord.gg/Pc8HG9x

Coin Marketplace

STEEM 0.17
TRX 0.15
JST 0.028
BTC 57653.84
ETH 2354.20
USDT 1.00
SBD 2.35