摘要:
在 R12B 中,构造和匹配二进制型最自然的方式比前版中的要快得多。你可用如下简单的代码来构造一个二进制型:这么写(在 R12B 中)/求别这么写(在 R12B 之前的版本中)my_list_to_binary(List) -> my_list_to_binary(List, >).my_list_... 阅读全文
摘要:
1 puts "hello world" 2 3 "Hello, Ruby.".index("Ruby.") 4 5 x = 0 6 puts "bigwhite" while (x = x + 1) r14 puts "value is #{r} less" if x < r15 puts... 阅读全文
摘要:
Given an array of integers, find two numbers such that they add up to a specific target number.The function twoSum should return indices of the two nu... 阅读全文
摘要:
-module(demo).-compile(export_all).foo() -> receive after 100000 -> io:format("ok~n") end.main() -> register(name1, spawn(fun()... 阅读全文