100 C programs, 100 C classics

Updated on technology 2024-04-23
4 answers
  1. Anonymous users2024-02-08

    Trash college students! Fighters in garbage, garbage, garbage!

  2. Anonymous users2024-02-07

    I don't even understand this, what kind of university to study! What kind of computer to learn! What programming to learn!

    Fighters in the garbage.

    Close the questions so you don't lose sight!

    Cope with homework!

  3. Anonymous users2024-02-06

    Topic:Find prime numbers within 100.

    Topic: DisrespectSort the number of 10.

    Program Analysis:The bubbling sort used here is to do 10-1 sorting, each time iterating through the entire array, comparing the current position to the magnitude of the next number of positions.

    Topic:Find the sum of the diagonal elements of a 3*3 matrix.

    Program Analysis:Use the double for loop control to input a two-dimensional array, and then set the .

    Output after accumulation.

    Topic:There is an array that is already ordered. Enter a number first and ask it to be inserted into the array according to the original pattern.

    Program Analysis:First, judge whether this number is greater than the last number, and then consider the case of inserting the middle number, and then move the number after the element back one position in turn.

    Here the program analysis is talking about the situation from small to large, what if it is another situation? )

    Topic:Output an array in reverse order.

    Procedural Analysis: BridgewoodI find an axis of symmetry and exchange one of the current position with one of the corresponding positions of the number from behind.

  4. Anonymous users2024-02-05

    Topic:How many distinct and unrepeating three-digit numbers can be formed into a single number? How much are they?

    Program Analysis:The numbers that can be filled in hundreds, tens, and single digits are all . After composing all the permutations, remove the permutations that do not meet the conditions.

    Topic:: The bonus issued by the enterprise is based on the profit commission. When the profit (i) is less than or equal to 100,000 yuan, 10% of the bonus can be withdrawn; When the profit is higher than 100,000 yuan and less than 200,000 yuan, the part less than 100,000 yuan will be paid 10% commission, and the part higher than 100,000 yuan will be commissioned; Between 200,000 and 400,000 yuan, the part higher than 200,000 yuan can be paid 5%; If it is between 400,000 and 600,000 yuan, the part higher than 400,000 yuan can be paid 3%; Between 600,000 and 1 million, the part higher than 600,000 yuan, can be commissioned, higher than 1 million yuan, more than 1 million yuan according to 1% commission, from the keyboard to enter the current month's profit i, the total amount of bonuses?

    Program Analysis:Please use the number axis to demarcate the socks and position. Note that when defining, the bonus needs to be defined as a growth integer.

    Question: What is the number of an integer, which is a perfectly squared number after adding 100, and a perfectly squared number after adding 168?

    Program Analysis:Judging within 100,000, first add 100 to the number and then open the square, and then add the number to 268 and then open the square, if the result after the opening meets the following conditions, it is the result.

    Topic:Enter a certain day, a certain month, and determine if this day is the first day of the year?

    Program Analysis:Take March 5 as an example, you should add up the previous two months, and then add 5 days, that is, the first day of the year.

    Question: Enter three integers x, y, z, please macro virtual excite the output of these three numbers from small to large.

    Program Analysis: We try to put the smallest number on x, first compare x with y, if x > y then swap x with y, then use x to compare z, if x > z then swap x with z value, so that x is the smallest.

Related questions
3 answers2024-04-23

The so-called suffix expression is to write a @ b as a b @其中前者是我们日常生活中的中缀表达式, followed by a suffix expression. >>>More

5 answers2024-04-23

Question 1: pt1=&a;pt2=&b;pt1 and pt2 are not defined, years are defined as. >>>More

7 answers2024-04-23

In the C language. An integer constant starting with 0 refers to octal. 027 is 2x8+7, so the answer is c.

7 answers2024-04-23

char *p;

uchar log_type; >>>More

7 answers2024-04-23

In the whole main function, only this one variable, whether it is the first for or the second for, is the same i, the second for will have i=-1, in the case of i= -1, and printf("%d ",a[i]);Statement. So fear not! When there is no second for the case: >>>More