This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <iostream> | |
| using namespace std; | |
| int main() | |
| { | |
| int a = 20; //声明一个int变量 | |
| int &b = a; //声明一个int引用 | |
| int *p = &a;//声明一个int指针 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <iostream> | |
| using namespace std; | |
| int main(){ | |
| int *p = new int; //在堆里创建指针 | |
| *p = 10; //将值赋给指针所指向的地址 | |
| cout<<"*p="<<*p<<endl; | |
| // delete p; | |
| p = new int; //内存泄露:没有释放之前的内存 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <iostream> | |
| using namespace std; | |
| class Animal | |
| { | |
| public: | |
| void move() const {cout<<"Animal move one step\n";} | |
| void move(int distance) const{ | |
| cout<<"Animal move "<<distance; | |
| cout<<" steps."<<endl; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!Doctype html> | |
| <html> | |
| <head> | |
| <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> | |
| <meta name="viewport" content="width=320px;initial-scale=1.0;"/> | |
| <title>三列布局</title> | |
| </head> | |
| <style> | |
| /*第一种布局样式*/ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <iostream> | |
| using namespace std; | |
| /** | |
| * 非递归二分查找 | |
| * @author Boychenney | |
| * @date 2013-10-24T11:02:43+0800 | |
| * @param r 数组指针 | |
| * @param n 数组大小 | |
| * @param k 待查找的值 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <iostream> | |
| using namespace std; | |
| /** | |
| * 一趟快排算法 | |
| * @author Boychenney | |
| * @date 2013-10-25T10:54:47+0800 | |
| * @param s 待排序的数组 | |
| * @param l 开始索引 | |
| * @param r 结尾索引 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| require.config | |
| paths: | |
| 'jquery':'../bower_components/jquery/jquery', | |
| 'bootstrap-affix':"../bower_components/bootstrap/js/affix", | |
| 'bootstrap-transition':"../bower_components/bootstrap/js/transition", | |
| "bootstrap-alert":"../bower_components/bootstrap/js/alert", | |
| "bootstrap-button":"../bower_components/bootstrap/js/button", | |
| "bootstrap-collapse":"../bower_components/bootstrap/js/collapse", | |
| "bootstrap-dropdown":"../bower_components/bootstrap/js/dropdown", | |
| "bootstrap-modal":"../bower_components/bootstrap/js/modal", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Generated on 2013-11-05 using generator-bootstrap-less 3.1.0 | |
| 'use strict'; | |
| var lrSnippet = require('grunt-contrib-livereload/lib/utils').livereloadSnippet; | |
| var mountFolder = function (connect, dir) { | |
| return connect.static(require('path').resolve(dir)); | |
| }; | |
| // # Globbing | |
| // for performance reasons we're only matching one level down: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| ** inspired by markgdyr, http://markgoodyear.com/2014/01/getting-started-with-gulp/ | |
| * date:2014年4月14日 | |
| * creator:玄农 | |
| * mail:bocheng.zbc@alibaba-inc.com | |
| **/ | |
| // Load the plugins | |
| var gulp = require("gulp"), | |
| less = require("gulp-less"), |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!DOCTYPE html> | |
| <html> | |
| <head> | |
| <meta name="description" content="数据魔方第一版" /> | |
| <meta charset="utf-8"> | |
| <title>数据魔方第一版</title> | |
| <script type="text/javascript" src="http://g.tbcdn.cn/kissy/k/1.4.2/seed-min.js" charset="utf-8"></script> | |
| </head> | |
| <body> | |
| <!-- 卖家成长魔方 --> |
OlderNewer