zoukankan      html  css  js  c++  java
  • Day6 function

     //                  **Day6

    //                                          **Functiion

     

    //func SayHello (value: String, value1:String)->String {

    //

    //    let str = value + "" + value1

    //    

    //    print("str (value)")

    //    return str

    //}

     

     

     

    //SayHello("Hello",value1: "World")

    //

    //

    //let string : String = SayHello("f",value1: "f")

     

    //

    //func SayHello(var value:String) {

    //    value = "AA"

    //    print(value)

    //}

    //

    //SayHello("hello")

     

     

    //func SayHello(values:Double...){

    //    for item in values{

    //        print("item : (item)")

    //    }

    //}

    //

    //SayHello(1.1,1.2,1.3)

     

    // summary: the func of params is dictionary

     

    //func SayHello(value:String,joinString value1:String) {

    //

    //    var str = value + value1

    //    print("str = (str)")

    //}

    //

    //SayHello("Hello,", joinString: "Swift")

     

    //summary:  set a out func name

     

    //func SayHello(inout value:String) {

    //

    //    value = "Hello Swift"

    //}

    //

    //var str = "Hello"

    //

    //SayHello(&str)

    //

    //print("(str)")

     

     

    // summary:  inout func  input string address   out change value

     

     

     

     

    //func SayHello(value:String,nums value1:String) -> (String,String) {

    //

    //    return (value,value1)

    //}

    //

    //

    //var (A,B) = SayHello("Hello", nums: "World")

    //

    //print("A:(A) B:(B)")

     

    // summary:  tuples

  • 相关阅读:
    Mac普通用户修改了/etc/sudoers文件的解决办法
    python对缓存(memcached,redis)的操作
    线程、进程、协程和队列
    python作用域和多继承
    sokect编程进阶
    socket编程基础
    python面相对象进阶
    python异常处理
    configparser模块
    subprocess模块
  • 原文地址:https://www.cnblogs.com/tony0571/p/5362020.html
Copyright © 2011-2022 走看看