![](https://img-blog.csdnimg.cn/20201014180756780.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
畅游C代码,做个简单的技术宅
其子昱舟
挣扎出深渊前,得明白自己处于深渊中。
展开
-
游玩C代码-符号常量(求圆的体积)
%lf是C语言中double的格式字符,用于格式化输入输出。#include<stdio.h>#define PAI 3.14 /*定义符号常量*/int main(){ double fRadius; /*定义半径变量*/ double fResult=0; /*定义结果变量*/ printf("请输...原创 2020-04-20 12:21:30 · 576 阅读 · 0 评论 -
游玩C语言-putchar输出字符函数 错误:cannot convert parameter 1 from 'char [2]' to 'int'
cannot convert parameter 1 from ‘char [2]’ to ‘int’This conversion requires a reinterpret_cast, a C-style cast or function-style cast错误意思是:字符单双撇号使用错误,将下列“” ,修改为 ‘ 即可。#include<stdio.h>int ...原创 2020-04-20 12:16:31 · 1599 阅读 · 0 评论 -
游玩C代码-计算长方体的体积
undeclared identifier 错误redefinition; different type modifiers 错误#include<stdio.h>#define Height 10int acalculate(int Long,int Width); //第一个错误出现在这里,没用定义直接使用int main(){ int m_Lo...原创 2020-04-20 12:04:51 · 394 阅读 · 0 评论 -
游玩C代码-根据父母身高预测儿子身高(代码)
#include<stdio.h>#define HEG 0.54 //定义常量,全文通用时可以在开头定义常量,减少重复构建float height(float father,float mother);int main(){ //定义父亲、母亲、儿子变量身高【全局变量】 float father; float mother; float son; print...原创 2020-04-20 11:46:38 · 3029 阅读 · 0 评论