- Data types, variables and constants
- Ввод с клавиатуры и вывод данных на экран
- Арифметические операции и комбинированные операторы
- Операторы выбора if и else в С
- The switch statement in C ++
- The for loop in C++
- Циклы while, do while, nested loops
- Two-dimensional arrays C ++
- Arrays in C++
- Functions in C++
- Pointers C ++
- A pointer to a pointer to C ++
- Classes in C ++
Additional collection of problems with solutions
This page contains all of the tasks on the topics lessons, posted on our website. К каждой задаче прилагается наш вариант решения. Постарайтесь всё же решать их самостоятельно и только потом сравнивать наш исходный код со своим. “Хочешь научиться программировать – программируй”!
Больше практических заданий с решениями найдёте here.
Рекомендуем посетить Сайт для юных программистов – где вы найдете уроки по различным языкам программирования (в том числе для детей), 3D-моделированию, Linux и др.
S.O.S.
program structure. Functions.
Develop a library of functions to perform operations with binary
wood. There should be a function of adding a tree node,
removal unit, search and analysis of the need for balancing.
Questions and Tasks:
1.Design an algorithm for solving the problem and write a program in C
(С ), compile and debug it.
2. Check the correct operation of the program, ensure stability
algorithm.
3. What are the advantages of using shared libraries, how to create and
to use a shared library. Create a shared library
written functions.
opachki sho you here
Level navichok slozhnostash 16
hairy business
(Time: 1 sec. Memory: 16 MB complexity: 32%)
One Neformal fired from his job, and now he had to somehow earn a living. reflection, he decided, that can be very good money by selling your own hair. It is known, that the collection points to buy the hair of any length cost cu. for every centimeter. Since the hair is a very dynamic market, the price of one centimeter of hair changes every day as well as the exchange rate. Neformal is a very good business analyst. He was able to calculate, what will be the price of one centimeter of hair in each of the next N days (for the convenience of the days are numbered in chronological order of 0 to N-1). Now he wants to define, in which of these days he should sell hair, that at the expiration of N days to earn the most money. Note, that hair Neformal only grow and grow on the night 1 centimeter per night. It should also be taken into account, that prior to the 0th day neformal grief cropped haircut and to 0 by day his hair length was 1 centimeter.
Input data
The first line INPUT.TXT input file contains the integer N (0 < N ≤ 100). In the second line N set of natural numbers, not exceeding 100, the corresponding value of C[i] 1 centimeter of hair for each i-th day.
Output
The output file a single line OUTPUT.TXT need to bring the maximum amount of money, you can earn neformal of N days.
examples
№ INPUT.TXT
5
73 31 96 24 46
OUTPUT TXT
380
___________________
INPUT.TXT
10
1 2 3 4 5 6 7 8 9 10
OUTPUT.TXT
100
____-__-____________
10
10 9 8 7 6 5 4 3 2 1
Output
55
Can someone help)?
Write a program, implements merge sorting algorithm for double precision real numbers. Necessary, so that the program returns a pointer to a new dynamically created array, containing sorted input sequence.
Help is needed
write a block diagram and a program, defining, which of the two values of resistance R1, R2, R3 can be obtained using two resistors 6 kOhm
1. R1 = 6, R2-10, R3=2
1. R1 = 3, R2-5, R3=7
1. R1 = 4, R2-12, R3=8
Matrix elements A[ij]m,n, equal to zero change to min
element of the matrix B[ij]m,n .Task
Matrix elements A[ij]m,n, equal to zero change to min
element of the matrix B[ij]m,n .
From the entered list to display surnames with the set number of letters. Task