Case1:
#include
#include
#include
char* getMem(void)
{
      char  p[] = "hello world";//这样子定义可以输出,但输出乱码。
      p[5] = 0x0;
      return p;
}
int main()
{
    char *s="fzz";
    s=getMem();
    pri...
                            
                            
                                分类:
其他好文   时间:
2015-04-07 09:58:26   
                                阅读次数:
108
                             
                    
                        
                            
                            
                                要求://****file: stack.h/*对stack进行初始化检查stack为空,或已满将整数压入到stack中从stack里弹出整数 不移除任何袁术,讲过stack的内容输出到标准输出Stack类的私有成员如下:一个用于打印错误信息的私有哦成员函数三个私有数据成员构成了stack类的pri...
                            
                            
                                分类:
编程语言   时间:
2015-04-03 20:54:59   
                                阅读次数:
141
                             
                    
                        
                            
                            
                                SELECT a.*,GROUP_CONCAT(b.pri_name) FROM sh_role a LEFT JOIN sh_privilege b ON FIND_IN_SET(b.id,a.pri_id_list) GROUP BY a.id;
                            
                            
                                分类:
其他好文   时间:
2015-04-02 13:17:53   
                                阅读次数:
89
                             
                    
                        
                            
                            
                                1.如下代码所示#include #include #include int main(int argc,char *argv[]){ pid_t child = fork(); if( child == -1 ) { //error pri...
                            
                            
                                分类:
系统相关   时间:
2015-04-01 16:56:56   
                                阅读次数:
189
                             
                    
                        
                            
                            
                                现在用orm比较多,很多mysql表啊都不用自己创建,但是数据库还是要自己创建,记录下sql,  备忘。
CREATE DATABASE `mydb` CHARACTER SET utf8 COLLATE utf8_general_ci;
GRANT ALL ON `mydb`.* TO `username`@localhost IDENTIFIED BY 'password';
FLUSH PRI...
                            
                            
                                分类:
数据库   时间:
2015-03-31 22:15:36   
                                阅读次数:
154
                             
                    
                        
                            
                            
                                有两种方法使用log 
log类 
log level: 
verbose:任何消息 
debug:输出调试消息 
information:一般提示性的信息,包括i,w,e 
warning:警告 
error:错误 
assertLogPrinter类:发送输出到系统log, 
构造函数 
public LogPrinter (int priority, String tag) 
参数: 
pri...
                            
                            
                                分类:
移动开发   时间:
2015-03-31 09:07:32   
                                阅读次数:
141
                             
                    
                        
                            
                            
                                interface Station{ void sellTickets();}class TrainStation implements Station{	public TrainStation()	{	}	public void sellTickets()	{ System.out.pri...
                            
                            
                                分类:
编程语言   时间:
2015-03-30 20:49:28   
                                阅读次数:
141
                             
                    
                        
                            
                            
                                变量使用注意2:
#include<stdio.h>
/*
1.变量的作用域
从定义变量的那一行代码开始,一直到所在的代码块结束
2.代码块的作用
及时回收不再使用的变量,为了提升性能
*/
inttest()
{
intv=10;
return0;
}
intmain()
{
{
doubleheight=1.55;
height=height+1;//1.55+1
pri..
                            
                            
                                分类:
编程语言   时间:
2015-03-29 18:11:36   
                                阅读次数:
156
                             
                    
                        
                            
                            
                                http://acm.hdu.edu.cn/showproblem.php?pid=4403
Problem Description
Aoshu is very popular among primary school students. It is mathematics, but much harder than ordinary mathematics for pri...
                            
                            
                                分类:
其他好文   时间:
2015-03-29 12:16:05   
                                阅读次数:
151
                             
                    
                        
                            
                            
                                运算符是用来完成一个动作的特定语言的语法记号。 –赋值运算符 –增减运算符 –算术运算符 –关系运算符 –逻辑运算符 -位运算符 运算符Java加+减-乘*除/取模%1.整数运算和小数运算int n =12 ;int m = 5;float y = n/m;System.out.pri...
                            
                            
                                分类:
编程语言   时间:
2015-03-21 22:46:46   
                                阅读次数:
192