This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| echo dateDayFormat("today", "tr") // "2022-10-13" | |
| // Output: 13, 14 ve 15 Ekim 2022 | |
| // ----------------------------------------- | |
| echo dateDayFormat("2022-12-30", "tr") | |
| // Output: 30, 31 Aralık 2022 ve 1 Ocak 2023 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const sayHello = () => "Merhaba"; | |
| sayHello(); | |
| // output: Merhaba | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const sum = (a, b) => { | |
| const c = a * 2; | |
| const d = b * 2; | |
| const result = a + b + c + d; | |
| return result; | |
| // süslü parantez kullandığımızda geri sonuç döndürmek için bir "return"'a ihtiyacımız olacak. | |
| } | |
| sum(3, 5); | |
| // output: 24 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const sayHello = name => `Merhaba ${name}`; | |
| sayHello("Ferdi"); | |
| // output: Merhaba Ferdi | |
| sayHello("Meryem"); | |
| // output: Merhaba Meryem | |
| // --------------------------- |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const multiply = function(a, b) { | |
| return a * b; | |
| } | |
| multiply(3, 5); | |
| // output: 15 | |
| multiply(2, 40); | |
| // output: 80 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const multiply = (a, b) => a * b; | |
| multiply(3, 5); | |
| // output: 15 | |
| multiply(2, 40); | |
| // output: 80 | |
| // --------------------------- |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Function Declaration | |
| function sayHello(name) { | |
| return `Merhaba, ${name}!`; | |
| } | |
| sayHello("Ferdi"); | |
| // output: Merhaba Ferdi | |
| // --------------------------- |