光立方程序详解_C ++程序使用宏查找数字的立方
光立方程序詳解
Also Read:?C++ program to swap two numbers using macros
Also Read:?C++ Program to find cube of a number using function
#include<iostream.h>
#include<conio.h>
#define CUBE(x) (x*x*x)
void main()
{
clrscr();
int n,cube;
cout<<“Enter a number:”;
cin>>n;
cube=CUBE(n);
cout<<“Cube=”<<cube;
getch();
}
Also Read:?C++ program to swap two numbers using macros
Also Read:?C++ Program to find cube of a number using function
#include<iostream.h>
#include<conio.h>
#define CUBE (x) (x*x*x)
void main()
{
clrscr();
int n,cube;
cout<<“Enter a number:”;
cin>>n;
cube=CUBE(n);
cout<<“Cube=”<<cube;
getch();
}
翻譯自: https://www.thecrazyprogrammer.com/2013/06/c-program-to-find-cube-of-number-using.html
光立方程序詳解
總結
以上是生活随笔為你收集整理的光立方程序详解_C ++程序使用宏查找数字的立方的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: 前端学习(2670): vue3.0实战
- 下一篇: 工作126:Vue.ls.set传值 然