Print | Swift Tutorial | Hello World
- Octopus

- 2. Jan. 2021
- 1 Min. Lesezeit
Aktualisiert: 10. Jan. 2021
Mit der Funktion print() kann man Inhalte auf der Konsole ausgeben. Dies ist besonders Hilfreich bei der Fehlersuche, dem sogenannten Debugging. In der Konsole können Zeichenketten, Zahlen oder auch Kombinationen von Zahlen und Zeichenketten ausgegeben werden.
Strings "Hello World" in der Konsole ausgeben
print("Hello World")
Output: Hello WorldZahlen in der Konsole ausgeben
print(1)
Output: 1Variablen in der Konsole ausgeben
var text = "Ergebnis"
print(text)
Output: ErgebnisMehrere Variablen in der Konsole ausgeben
var text = "Ergebnis"
var zahl = 1
print(text, zahl)
Output: Ergebnis 1Berechnungen in der Konsole ausgeben
var text = "Ergebnis"
var zahl = 1
var zahl2 = 2
print(text, zahl + zahl2)
Output: Ergebnis 3Du liest: Print | Swift Tutorial | Hello World

The Famous fonts instantly add sophistication to a project – I used famous fonts for a logo concept and they gave it a timeless feel. On the other hand, the Fat fonts are bold and playful, great for posters or ads where you want something eye-catching. I think both categories have their charm: one is elegant and classy, the other fun and loud. Depending on what mood you want to create, these fonts can really help you stand out.