灵活使用GOTO语句

文章作者 100test 发表时间 2007:10:24 12:50:46
来源 100Test.Com百考试题网


看了下面这个例子你肯定会惊叹GOTO语言原来可以这样用啊,呵呵。
#include
#include
using namespace std.
class B{
public:
B(){
cout << "BBBBBBBBBBBB" < }.

~B(){
cout << "SHB" << endl.
}.
protected:
private:
}.
int func(...){
cout << "EN".
return 0.
}.
int main (int argv,char* argc[]){
char * str_1 = "HelloTEST".
char str_2[200] .

func(1,"ABC",false).
memset(str_2,’F’,200).
strcpy(str_2,str_1).
const int ** p.
int * const *q.
while(1)
{
B b.
//goto HEIHEI. 屏蔽掉goto 和开启goto 看看 B的析构函数是怎么跑的,能正确析构吗?goto都干了什么。
}
HEIHEI: int ABC = 0.
return 0.
}


相关文章


在GraphEdit中显示应用程序的Filtergraph的方法
C 私有成员变量的访问权限研究
VC 编译选项说明
防止窗口闪烁的方法
灵活使用GOTO语句
用C语言封装的链表的方法
miranda中Service与Event机制分析其结果
qsort()排序函数的使用qsort函数应用大全
澳大利亚华人论坛
考好网
日本华人论坛
华人移民留学论坛
英国华人论坛