(1) Swift can carry out% of floating-point numbers, and OC and C are only for integers
(2) Like C, Swift has only one Mihara operator, which is the three-mesh operator
(3)
(4) splicing can be achieved
Let temp = "Hello," + "world"
println (temp)
(5) Modulus and redundancy is a meaning
(6) Take the reverse
(7) Composite operation
(8) Comparison operators
(9) Three mesh operator: Question? Answer 1: Answer 2
(10) null-fit operator
For example, determine optional type a:
A! = nil? A! : b Determines if optional type A is empty, if not empty, just! Forcibly unlocks the value and, if it is empty, returns the default value, B. Assignment is not involved here, it is to determine who the return value is. This can be troublesome, with the empty operator is simple: a?? B is realized (to a null judgment, not empty to forcibly unpack, empty return B), forced to extract the value is also called a packet
(11) Interval operator
1. Closed interval operator a...b
2. Semi-open interval operator A: <b commonly used to denote arrays or something because B is not included
02.swift Basic Operations