Vc 6 0
This presentation is the property of its rightful owner.
Sponsored Links
1 / 54

使用 VC++6.0 调试程序 PowerPoint PPT Presentation


  • 112 Views
  • Uploaded on
  • Presentation posted in: General

使用 VC++6.0 调试程序. 调试程序. 调试运行 单步跟踪 单步跳进跟踪 观察自动变量 观察其他变量 停止调试. 1 :打开 jiecheng 项目(双击 jiecheng.dsw 文件) 2 : build 该项目,确定程序可以运行 3 :调试运行阶乘程序 4 :设置断点 5 :再次调试运行程序 6 :使用单步执行程序到结束. 1 :打开 jiecheng 项目. 2 : Build 该项目,确定程序可以运行. Go. 3 :调试运行阶乘程序. 4 :设置断点.

Download Presentation

使用 VC++6.0 调试程序

An Image/Link below is provided (as is) to download presentation

Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.


- - - - - - - - - - - - - - - - - - - - - - - - - - E N D - - - - - - - - - - - - - - - - - - - - - - - - - -

Presentation Transcript


Vc 6 0

VC++6.0


Vc 6 0


Vc 6 0

  • 1jiechengjiecheng.dsw

  • 2build

  • 3

  • 4

  • 5

  • 6


1 jiecheng

1jiecheng


2 build

2Build


Vc 6 0

Go

3


Vc 6 0

4

  • 888i = i*4;

  • 8


Vc 6 0

Go

5


Vc 6 0

Debug

5


Vc 6 0

6


Vc 6 0

6

  • Step Over


Vc 6 0

Debug


Vc 6 0


Vc 6 0

  • Debug

    Quick Watch


Vc 6 0

Add Watch


Add watch

Add watch


Vc 6 0

i

  • i


Vc 6 0

  • F5


Vc 6 0

C


Vc 6 0


Visual c

Visual C++

WindowsVisual C++C

1

2


Visual c1

Visual C++

Visual C++

Visual C++


Visual c2

Visual C++


Vc 6 0

1&

2. *

exp:

&a: a

*p: p

&


Vc 6 0

2010

p

q

2012

2010

a

b

2012

C


Vc 6 0

*;

int i, j, *pi, *pj;

float x, y, *p1, *p2;

&;

pi=&i; pj=&j; p1=&y; p2=&x;

pipjintp1, p2float


Vc 6 0


Vc 6 0

*

:

int i, *p;

p=&i;

i=5;*p=5;*pi,*


Vc 6 0

10.310.2

swap(int *p1, int *p2)

{int temp;

temp=*p1; *p1=*p2; *p2=temp;

}

main()

{int a, b, *pointer1,*pointer2;

scanf("%d%d",&a,&b);

pointer1=&a; pointer2=&b;

if(a<b) swap(&a,&b);

printf("\n%d,%d",a,b);

}


Vc 6 0

1.

2.---

int a [10], *p=a (*p=&a[0]);int a [10], *p;

pa;


Vc 6 0

3.

int a [10],*p=a;

1p+i==a+i==&a[i]

2*(p+i)==*(a+i)==a[i]

3p[i]*(p+i)a[i]

p+1p+1p+1*size(size

p3000p+13000+1*2=30023001


Vc 6 0


Vc 6 0

1.


Vc 6 0

2. 1

(*)( ) * int (*fp)(); /* fpint*/


Vc 6 0

2 [&]; &


Vc 6 0

(3)

(*)([])

3.

p+ip++/p--

10.24

processabab


Vc 6 0

#include<stdio.h>

void main()

{int max(int,int);

int min(int,int);

int add(int,int);

int process(int, int, int (*fun)());

int a,b;

printf("enter a and b:");

scanf("%d%d",&a,&b);

printf("\nmax=");

process(a,b,max);

printf("\nmin=");

process(a,b,min);

printf("\nsum=");

process(a,b,add);

}


Vc 6 0

max(int x, int y)

{return x>y?x:y;}

min(int x, int y)

{return x>y?y:x;}

add(int x, int y)

{return x+y;}

process(int x, int y, int (*fun)(int,int)) /*fun*/

{int result;

result=(*fun)(x,y);

printf("%d\n",result);

}


Vc 6 0

intfloatchar

*()

int *a(int x,int y);

a


Vc 6 0

*[]

int *p[4]; char *string[10];


Vc 6 0

*p++,*p(++),*(++p),(*p)

Pai

*(p--)==a[i--];

*(--p)==a[--i];

*(++p)==a[++i].

pa


Vc 6 0


Vc 6 0

C


Vc 6 0

struct

{ 1

2

n

};

struct student

{ char name[10];

long id;

char gender;

int age;

}

struct student

name[10]idgenderage

struct


Vc 6 0

(1) : 10

struct student

{ int no /**/

char name10 /**/

char sex /**/

int age /**/

float score[10] /**/

}


Vc 6 0

1.

struct

struct student

struct student zhang ,stu1


Vc 6 0

2.

struct

{ 1

2

n

} ;

struct student

{ char name[10];

char sex;

int age;

float score;

} stu1,stu2;


Vc 6 0

3.

struct

{ 1

2

n

} ;

struct

{ char name[10];

char sex;

int age;

float score;

} stu1,stu2;

1

2

3

4


Vc 6 0

stu1:

struct student stu1;

stu1.age=20;

scanf("%f",&stu1.score);

stu1.age stu1ageintint

.


Vc 6 0

(1) ,

(2)

scanf(%s%c%d%f,&stu1);

(3)

stu1=stu2;

(4)

(5) stu1

stu1.birthday.day=23

stu1.birthday.month=8

stu1.birthday.year=1985


Vc 6 0

struct

{

} ={}

struct student

{ char name[10];

char sex;

int age;

float score;

}stu1,stu2={Wangwu,m,20,88.5};


Vc 6 0


Vc 6 0

struct student *pstu, stu;

pstu=&stu;

pstu,stu

*pstu pstustu*pstu).name ,(*pstu).age

struct *

C

->

->

*pstu).name,(*pstu).age

pstu->name, pstu->age


Vc 6 0

p->n

p->n++

++p->n

.

(*p).

p->

->

p->n

(p->n)++

++(p->n)


  • Login