C 练习实例56

C语言教程评论

C 练习实例56

题目:画图,学用circle画圆形。

程序分析:无。文章源自公式库网-https://www.gongshiku.com/html/202112/c-lianxishili56.html

实例

复制代码文章源自公式库网-https://www.gongshiku.com/html/202112/c-lianxishili56.html
#include <graphics.h> //VC6.0中是不能运行的,要在Turbo2.0/3.0中  
int main()   
{  
    int driver,mode,i;   
    float j=1,k=1;   
    driver=VGA;  
    mode=VGAHI;   
    initgraph(&driver,&mode,"");   
    setbkcolor(YELLOW);   
    for(i=0;i<=25;i++)   
    {   
        setcolor(8);   
        circle(310,250,k);   
        k=k+j;   
    j=j+0.3;   
    }   
    return 0;  
}
文章源自公式库网-https://www.gongshiku.com/html/202112/c-lianxishili56.html文章源自公式库网-https://www.gongshiku.com/html/202112/c-lianxishili56.html
运营不易,
感谢支持!
weinxin
我的微信
我的微信公众号
我的微信公众号扫一扫
weinxin
我的公众号
 最后更新:2021-12-7
公式库网
  • 本文由 公式库网 发表于 2021年12月6日20:44:09
  • 转载请务必保留本文链接:https://www.gongshiku.com/html/202112/c-lianxishili56.html

发表评论