2015-07-28 张炎泼
对于一个tcp连接,在c语言里一般有2种方法可以将其关闭: c close(sock_fd); 或者 c shutdown(sock_fd, ...); more 多数情况下这2个方法的效果没有区别,可以互换使用。除了: 继续阅读 »
2016-08-23 craneyuan
本文就关于IO资源的处理问题,提出三种方案。 close()放在try块中 close()放在finally块中 使用try-with-resource语句 close()放在try块中 more //close() is in try clause try { PrintWriter out = new PrintWriter( new BufferedWriter( new FileWriter("out.txt", true))); out.println("the text"); out.close(); } catch (IOException 继续阅读 »
2015-06-25 王财勇
配置Mathjax 由于Jacman主题支持写 LaTex 数学公式,因此只需要做到下面两步,即可使用。 1、在主题Jacman的_config.yml加入mathjax: true,即 close_aside: false #close sidebar in post page if true mathjax: true #enable mathjax if true 2、在文章文件开头的前言中,加上一行mathjax: true,即可在文中写 LaTex 公式。 ``` title: 测试Mathjax date: 2014-2-14 23:25:23 tags: Mathmatics categories: 继续阅读 »