ex1203c.cpp

来自「经典的fortran95编程书,知名作者彭国伦 书的配套原程序,」· C++ 代码 · 共 32 行

CPP
32
字号
#include <stdio.h>

#ifdef __cplusplus
extern "C" {
#endif

void sub1(char *num)
{
	printf("%s\n",num);
}

void sub2(float r, float i)
{
	printf("%5.2f, %5.2f\n",r, i);
}

typedef struct _person
{
  int   age;
  float weight, height;
} person;

void sub3(person p)
{
	printf("age:%d weight:%5.2f height:%5.2f\n", 
		    p.age, p.weight, p.height);
}

#ifdef __cplusplus
}
#endif

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?