Array and sparse matrix

catalogue 1, Definition of array 1. Definition of one-dimensional array 2. Definition of two-dimensional array 2, Storage structure of array 1. Array storage mode 2. Storage mode of two-dimensional array (1) Priority storage by row (2) priority storage mode by column 3, Matrix 1. Definition of matrix 2. Definition of special matrix ...

Added by artyfarty on Fri, 11 Feb 2022 08:37:41 +0200

Advanced C language 9: memory

1. Structure byte alignment 1.1 try #include <stdio.h> struct S1{ char c1; char c2; int n; }; struct S2{ char c1; int n; char c2; }; struct S3{ int n; char c1; char c2; }; int main(){ printf("sizeof(struct S1) = %ld\n",sizeof(struct S1)); printf("sizeof(struct S2) = %ld\n",sizeof(struct S2)); prin ...

Added by kippy on Thu, 10 Feb 2022 19:38:24 +0200

Solutions to group C/C++A questions of the 11th Blue Bridge Cup in 2020 (excluding the last two questions)

A house plate making Title Description Calculate the number of characters 2 from 1 to 2020. thinking The amount of data is very small, direct violence, and the number of 2 can be counted for each number. code #include<iostream> #include<algorithm> using namespace std; int main() { int ans = 0; for (int i = 1; i <= 2020; i ...

Added by sbinkerd1 on Thu, 10 Feb 2022 13:55:01 +0200

BUAA (spring 2021) minimum wiring (diagram) -- Prim(BFS + greed) + Kruskal (parallel search set) double solution + principle explanation

Notice before reading Key points introduction and brief statement. The seventh computer question is be ing updated Topic content Problem description The main office and scientific research buildings of Beihang include new main building, Yifu Building, such as heart building, office building, library, main building, building 1, etc;. Be ...

Added by NewbieBryan on Thu, 10 Feb 2022 01:24:51 +0200

2021 12th Lanqiao cup provincial tournament group B C/C++

2021 12th Lanqiao cup provincial tournament group B C/C++ preface: Recall that I participated in the blue bridge cup for the first time last year. At that time, I was a freshman and full of enthusiasm. Although I only learned c language and had only a little contact with c + +, I signed up for the competition at the suggestion of my senio ...

Added by horseatingweeds on Tue, 08 Feb 2022 20:28:07 +0200

C language data structure chapter - single cycle linked list creation, insertion, node deletion, printing and other operations

catalogue Familiar with circular linked list Definition of circular chain header node and data node Creation of circular linked list Insertion of circular linked list data node Deletion of circular linked list data node Traversal and printing of circular linked list Complete code Familiar with circular linked list After learning the ...

Added by olidenia on Tue, 08 Feb 2022 17:12:52 +0200

In depth analysis of data storage in memory shaping, storage in memory, and size end introduction

Deep analysis of data storage in memory Data type introduction Basic built-in types char //Character data type short //Short int //plastic long //Long integer long long //Longer shaping float //Single-precision floating-point double //Double precision floating point number Meaning of type: 1. Use this type t ...

Added by monezz on Tue, 08 Feb 2022 16:36:59 +0200

TS02N touch button driver for graffiti intelligent kettle software

preface The main content of this paper is to realize the touch key drive of the kettle, and the touch key chip adopts TS02N. 1, Key function setting of intelligent kettle The key functions of the intelligent kettle are set as follows. Before realizing the functions, we must first realize the drive of the key acquisition chip. functi ...

Added by DrJonesAC2 on Tue, 08 Feb 2022 10:16:14 +0200

C language array

array int a0,a1; -> This thing cannot be referenced through a loop. The name cannot be split. Arrays are introduced into all C languages Array definition: An array is a collection of data (variables) of the same type ​ int a0,a1…a99; -> If it is defined by an array - > a [100] represents 100 integer data ​ One dimensional a ...

Added by johncollins on Tue, 08 Feb 2022 03:25:32 +0200

C language loop structure

Loop structure (composed of loop statements such as while and for) 1, Problem introduction: Requirements: sum = 1 + 2 + ... + 100 sum = 0; i = 1; sum += i; i++; sum += i; i++; sum += i; i++; sum += i; i++; sum += i; i++; sum += i; ........ /*-> If we do this code manually, it's obvious that you'll go crazy All right, let the computer g ...

Added by jzhang1013 on Tue, 08 Feb 2022 03:11:56 +0200