说明:因为上个代码,总是要输入完整的绝对路径,比较麻烦,于是,就写了这个小程序,直接进入文件对话框选择需要运行的class文件。只需要提前输入完整的类名。测试的类:package cn.hncu.myJuniitApp;import cn.hncu.myJuniitApp.vo.MyTest;public class MyJunitTest { public void run1(){...
分类:
编程语言 时间:
2016-05-07 07:10:56
阅读次数:
267
递归更新父节点,然后lazy一下子节点#include
#include
using namespace std;
const int maxn=100010;
struct mytree
{
int lazy;
int me;
}tree[maxn*4];
void build(int node,int left,int right)
{...
分类:
其他好文 时间:
2016-05-07 06:59:42
阅读次数:
151
//节点 typedef struct bsnode{ int data; struct bstree *lchild; struct bstree *rchild; }bsnode,*bstree; 创建二叉排序树: 1创建二叉树: void createbstree(bstree &bt){ / ...
分类:
编程语言 时间:
2016-05-07 06:31:43
阅读次数:
284
storyboard文件的认识 用来描述软件界面 默认情况下,程序一启动就会加载Main.storyboard 加载storyboard时,会首先创建和显示箭头所指的控制器界面 IBAction和IBOutlet IBAction:本质就是void,能让方法具备连线的功能 IBOutlet:能让属性 ...
分类:
移动开发 时间:
2016-05-07 00:56:20
阅读次数:
210
/** * 将note.txt文件中每一行字符串读取出来并输出到控制台 * */ public class FileToConlse { public static void main(String[] args) { /*建立测试文件夹及文件对象*/ File dir = new File("." ...
分类:
其他好文 时间:
2016-05-06 21:57:23
阅读次数:
204
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace DelegateDemo1
{
class Program
{
static void Main(string[]...
分类:
编程语言 时间:
2016-05-06 19:41:34
阅读次数:
120
/// <summary> /// 清理回收站垃圾 /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void button1_Click(object sender, Even ...
function step(str) { location.href = "DetailsUserMgt.aspx?UserID=" + str;//跳转页面传值 } 前台JS方法 protected void btnCancel_Click(object sender, EventArgs e) ...
分类:
其他好文 时间:
2016-05-06 19:12:31
阅读次数:
133
#include
using namespace std;
/*堆中对象数组、对象指针数组*/
class stu
{
public:
void set(int x){i = x + 6;}
int get(){return i*i;};
private:
int i;
};
void main()
{
const int n = 1000;
stu * p = new stu[n];...
分类:
编程语言 时间:
2016-05-06 16:23:57
阅读次数:
193
模板与泛型编程
本文尝试着介绍对泛型编程的理解,从而扩展我们的template编程。泛型编程是C++中非常重要的一部分,它使得我们节省了很多编写不同代码的体力。
1. 了解隐式接口和编译器多态与OOP的不同之处面向对象编程世界总是以显式接口和运行期多态解决问题。例如:void doProcessing( Widget &w) {
if (w.size() > 10 && w != som...
分类:
编程语言 时间:
2016-05-06 16:01:48
阅读次数:
166