<?xml version="1.0" encoding="utf-8" ?><rss version="2.0"><channel><title><![CDATA[AndyKnow的专栏]]></title><description><![CDATA[勇敢走自己的路, 面向前方......]]></description><link>https://blog.youkuaiyun.com/AndyKnow</link><language>zh-cn</language><generator>https://blog.youkuaiyun.com/</generator><copyright><![CDATA[Copyright &copy; AndyKnow]]></copyright><item><title><![CDATA[3、耶稣有13个门徒，其中有一个就是出卖耶稣的叛徒，请用排除法找出这位叛徒：13人围坐一圈，从第一个开始报号：1，2，3，1，2，3...。凡是报到“3”就退出圈子，最后留在圈子内的人就是出卖耶稣的叛]]></title><link>https://blog.youkuaiyun.com/AndyKnow/article/details/42010113</link><guid>https://blog.youkuaiyun.com/AndyKnow/article/details/42010113</guid><author>AndyKnow</author><pubDate>Thu, 18 Dec 2014 20:05:07 +0800</pubDate><description><![CDATA[int a[13] = {1,2,3,4,5,6,7,8,9,10,11,12,13};
    int number = 13; //记录圈内剩余的人数
    int count = 0; //通过计算器来模拟报数
    int i = 0; //循环变量
    while (number > 1) {
        if (a[i] != 0) {
            count+]]></description><category></category></item><item><title><![CDATA[编程在一个已知的字符串中查找最长单词，假定字符串中只含字母和空格，用空格来分隔单词。]]></title><link>https://blog.youkuaiyun.com/AndyKnow/article/details/42009997</link><guid>https://blog.youkuaiyun.com/AndyKnow/article/details/42009997</guid><author>AndyKnow</author><pubDate>Thu, 18 Dec 2014 19:57:59 +0800</pubDate><description><![CDATA[char str[255] = {0};
    printf("请输入一个字符串:\n");
    scanf("%[^\n]", str);//意思是非'\n'。也就是说只要没有遇到换行就继续输入，当遇到换行符的时候此语句结束。而默认情况是遇到换行语句执行结束，但是str的值只是第一个空格前的值。但这样写，按回车时scanf执行完，中间所有内容包括空格都会输入到str中去。
//    ge]]></description><category></category></item><item><title><![CDATA[随机产生20个[10 , 50]的正整数存到数组中，并求数组中的所有元素最大值、最小值、平均值以及各元素之和,及第二大值。]]></title><link>https://blog.youkuaiyun.com/AndyKnow/article/details/42009779</link><guid>https://blog.youkuaiyun.com/AndyKnow/article/details/42009779</guid><author>AndyKnow</author><pubDate>Thu, 18 Dec 2014 19:43:52 +0800</pubDate><description><![CDATA[int a[20] = {0};//定义一个长度为20的数组a
    int max = 0;//用来存储数组a中所有元素的最大值
    int min = 0;//用来存储数组a中所有元素的最小值
    int sum = 0;//用来存储数组a各元素的和
    float aver = 0.0;//用来存储数组a中所有元素的平均值
    int secondMax = 0;//用来存]]></description><category></category></item><item><title><![CDATA[给定某年某月某日,输出其为这一年的第几天。]]></title><link>https://blog.youkuaiyun.com/AndyKnow/article/details/42009671</link><guid>https://blog.youkuaiyun.com/AndyKnow/article/details/42009671</guid><author>AndyKnow</author><pubDate>Thu, 18 Dec 2014 19:36:21 +0800</pubDate><description><![CDATA[int y = 0, m = 0, d = 0;
    int sum = 0;//用来存储其位这一年的第几天
    printf("第七题:请输入年月日:");
    scanf("%d%d%d", &y, &m, &d);
    int a[12] = {31, 29, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31};
    int b[12] = {]]></description><category></category></item><item><title><![CDATA[想学好OC, 需要的C语言必备知识点]]></title><link>https://blog.youkuaiyun.com/AndyKnow/article/details/42006793</link><guid>https://blog.youkuaiyun.com/AndyKnow/article/details/42006793</guid><author>AndyKnow</author><pubDate>Thu, 18 Dec 2014 16:07:05 +0800</pubDate><description><![CDATA[一. 基本数据类型, 变量 , 常量, 运算符
     1. 数据类型: int, short, char, long, float, double,
     2. 常量的分类: (1) 整型常量 (2)浮点型常量 (3)字符常量 (4)字符串常量
     3. 常量的特性: 常量存储在常量区, 常量区的内容不可被更改
     4. 变量的定义与本质: 数据类型 变量名 = 初值 ]]></description><category></category></item><item><title><![CDATA[c语言基础表达式, 关系运算符, 逻辑运算符, 位运算符, 数据的取值范围, 分支结构(if...else, switch...case)]]></title><link>https://blog.youkuaiyun.com/AndyKnow/article/details/41990319</link><guid>https://blog.youkuaiyun.com/AndyKnow/article/details/41990319</guid><author>AndyKnow</author><pubDate>Wed, 17 Dec 2014 22:40:34 +0800</pubDate><description><![CDATA[1.表达式: 表达式的判断是有无结果(值), 最简单的表达式是一个常量或变量, 如:12, a, 3 + 1, a + b, a + 5 都是表达式(变量已经赋过值)
2.BOOL(布尔)数据类型: c语言中除了基本数据类型, 还有BOO数据类型, 以及一些其它的数据类型, 如自定义的结构体数据类型
　　BOOL数据类型是一种表示非真即假的数据类型, 布尔类型的变量只有YES和NO两个值. Y]]></description><category></category></item><item><title><![CDATA[编写一个程序,输入两个包含 5 个元素的数组,先将两个数组升序排序,然 后将这两个数组合并成一个升序数组(合并排序)。]]></title><link>https://blog.youkuaiyun.com/AndyKnow/article/details/41990185</link><guid>https://blog.youkuaiyun.com/AndyKnow/article/details/41990185</guid><author>AndyKnow</author><pubDate>Wed, 17 Dec 2014 22:36:07 +0800</pubDate><description><![CDATA[int a[5] = {0}, b[5] = {0}, c[10] = {0};
    for(int i = 0; i < 5; i++) {
        a[i] = arc4random() % (30 - 10 + 1) + 10;//随机获取10 ~ 30之间的数
        printf("%d ", a[i]);
    }
    printf("\n");
    fo]]></description><category></category></item><item><title><![CDATA[冒泡排序]]></title><link>https://blog.youkuaiyun.com/AndyKnow/article/details/41988231</link><guid>https://blog.youkuaiyun.com/AndyKnow/article/details/41988231</guid><author>AndyKnow</author><pubDate>Wed, 17 Dec 2014 21:46:19 +0800</pubDate><description><![CDATA[int arr[10] = {0};//定义一个存放10个整型数的数组arr
    for (int i = 0; i < 10; i++) {//随机获取10个0 ~ 20的整数放到数组arr所对应的元素中, 并打印出来
        arr[i] = arc4random() % (20 - 0 + 1) + 0;
        printf("%d ", arr[i]);
    }
]]></description><category></category></item><item><title><![CDATA[c语言基础数据类型及命名规范]]></title><link>https://blog.youkuaiyun.com/AndyKnow/article/details/41985579</link><guid>https://blog.youkuaiyun.com/AndyKnow/article/details/41985579</guid><author>AndyKnow</author><pubDate>Wed, 17 Dec 2014 19:21:12 +0800</pubDate><description><![CDATA[1. 常量是程序运行期间不能被改变的量; 变量代表一个存储区域,存储区域内存储的内容就是变量的值, 变量的值可以在程序运行期间改变

　 (变量就像一个杯子, 用来存放水, 杯子里的水即变量的值是可以改变的)

2.基本数据类型:int: 整型类型, 在内存中占4个字节, 在计算机中每个字节都由8个二进位制数表示; short: 短整型类型, 在内存中占2个字节

　　　　　　　 lo]]></description><category></category></item><item><title><![CDATA[求最大公约数和最小公倍数(辗转相除法)]]></title><link>https://blog.youkuaiyun.com/AndyKnow/article/details/41980587</link><guid>https://blog.youkuaiyun.com/AndyKnow/article/details/41980587</guid><author>AndyKnow</author><pubDate>Wed, 17 Dec 2014 13:53:30 +0800</pubDate><description><![CDATA[int main() {
int x = 0, y = 0;
        printf("Please input two positive integers(正整数):");
        scanf("%d%d", &x, &y);//从控制台输入两个正整数
        int mul = x * y;//用来存放两个数的积, 因为辗转相除的过程中x和y的值会改变,所以先存储一下它们]]></description><category></category></item><item><title><![CDATA[求最大公约数和最小公倍数(普通方法)]]></title><link>https://blog.youkuaiyun.com/AndyKnow/article/details/41980517</link><guid>https://blog.youkuaiyun.com/AndyKnow/article/details/41980517</guid><author>AndyKnow</author><pubDate>Wed, 17 Dec 2014 13:37:22 +0800</pubDate><description><![CDATA[int  main() {
    int x = 0, y = 0;
    printf("Please input two positive integers(正整数):");
    scanf("%d%d", &x, &y);//从控制台输入两个正整数


    int min = x 
    int gcd = 1;//用来存放最大公约数
    for (int ]]></description><category></category></item><item><title><![CDATA[水仙花]]></title><link>https://blog.youkuaiyun.com/AndyKnow/article/details/41970765</link><guid>https://blog.youkuaiyun.com/AndyKnow/article/details/41970765</guid><author>AndyKnow</author><pubDate>Tue, 16 Dec 2014 23:04:57 +0800</pubDate><description><![CDATA[/**
 *  5. 编程将所有“水仙花数”打印出来,并打印其总个数。 “水仙花数”
    是一个 各个位立方之和等于该整数的三位数。
 */
void daffodil() {
    int count = 0;
    for (int i = 100; i < 1000; i++) {
        int a = i % 10;//a用来存放个位数字
        int b = ]]></description><category></category></item><item><title><![CDATA[随机产生 20 个[10 , 100]的正整数,输出这些数以及他们中的最大数]]></title><link>https://blog.youkuaiyun.com/AndyKnow/article/details/41970641</link><guid>https://blog.youkuaiyun.com/AndyKnow/article/details/41970641</guid><author>AndyKnow</author><pubDate>Tue, 16 Dec 2014 23:03:11 +0800</pubDate><description><![CDATA[/** *  4. 随机产生 20 个[10 , 100]的正整数,输出这些数以及他们中的最大数 */
void assignValue(int *arr, int n) {
    for (int i = 0; i < n; i++) {
        *(arr + i) = arc4random() %  (100 - 10 + 1) + 10;
        printf("%d ]]></description><category></category></item><item><title><![CDATA[打印三角形,四则运算]]></title><link>https://blog.youkuaiyun.com/AndyKnow/article/details/41959055</link><guid>https://blog.youkuaiyun.com/AndyKnow/article/details/41959055</guid><author>AndyKnow</author><pubDate>Tue, 16 Dec 2014 13:28:38 +0800</pubDate><description><![CDATA[void printGrap(int n) {
    for (int i = 0; i < n; i++) {
        for (int j = 0; j < n - 1 - i; j++) {
            printf(" ");
        }
        for (int k = 0; k < i + 1; k++) {
            printf(]]></description><category></category></item><item><title><![CDATA[打印菱形图形]]></title><link>https://blog.youkuaiyun.com/AndyKnow/article/details/41958177</link><guid>https://blog.youkuaiyun.com/AndyKnow/article/details/41958177</guid><author>AndyKnow</author><pubDate>Tue, 16 Dec 2014 11:45:26 +0800</pubDate><description><![CDATA[*  2. 打印下面图形(奇数行)
        *
       * *
      * * *
       * *
        *
 */
void printAnotherGrap(int n) {
    for (int i = 0; i < n / 2 + 1; i++) {
        for (int j = 0; j < n / 2 - i; j++) {
     ]]></description><category></category></item></channel></rss>