Ray's playground

 

2009年9月18日

Recipe 1.2 Substituting variables into strings

摘要: [代码]output: The number is 5.The number after 5 is 6.true[代码]output: Here is some text.To avoid triggering string interpolation, escape the hash characters or put the string in single quotes."\#{foo}"#... 阅读全文

posted @ 2009-09-18 23:12 Ray Z 阅读(124) 评论(0) 推荐(0) 编辑

Recipe 1.1 Building a string from parts

摘要: [代码]output:key1 is val1key2 is val2[代码]output: 1 and a 2 and a 3 and a1 and a 2 and a 3[代码]output: 1|2|3 阅读全文

posted @ 2009-09-18 22:00 Ray Z 阅读(206) 评论(0) 推荐(0) 编辑

C++ templates chapter 2(Function Templates)

摘要: Templates are compiled twice: Without instantiation, the template code itself is checked for correct syntax. Syntax errors are discovered, such as missing semicolons.At the time of instantiation, the ... 阅读全文

posted @ 2009-09-18 16:11 Ray Z 阅读(207) 评论(0) 推荐(0) 编辑

导航