본문 바로가기
728x90
반응형

c++5

Linked List(Check if Linked List is Palindrome) Linked List is a data structure comprising a sequence of nodes, each containing a reference to the subsequent node in the sequence. Linked lists are vital for dynamic memory allocation and offer primary operations such as insertion, deletion, and traversal. They come in handy when working with variable data sizes, enabling the efficient management of data storage and retrieval. Representation of.. 2023. 10. 3.
Stacks Stacks are containers of objects based on arrays that follow a Last-In-First-Out (LIFO) order, meaning that the most recently added item is removed first. Stacks are often used with the recursive backtracking algorithm and as the mechanism supporting the “undo” or “back” button in applications and browsers. Compilers often use stacks to parse the syntax of expressions before translating them int.. 2023. 10. 3.
Arrays An array is a sequential list of values. You can use arrays to store and access multiple values of the same data type under one identifier. Arrays makes it easier to perform operations on an entire dataset. They’re also great for retrieving data. There are one-dimensional arrays and multi-dimensional arrays. The values stored in an array are called elements. Elements are stored in consecutive bl.. 2023. 10. 3.
cordforces - A. Next Round "Contestant who earns a score equal to or greater than the k-th place finisher's score will advance to the next round, as long as the contestant earns a positive score..." — an excerpt from contest rules. A total of n participants took part in the contest (n ≥ k), and you already know their scores. Calculate how many participants will advance to the next round. Input The first line of the input .. 2018. 1. 24.
cordforces - A. Theatre Square Theatre Square in the capital city of Berland has a rectangular shape with the size n × mmeters. On the occasion of the city's anniversary, a decision was taken to pave the Square with square granite flagstones. Each flagstone is of the size a × a. What is the least number of flagstones needed to pave the Square? It's allowed to cover the surface larger than the Theatre Square, but the Square ha.. 2018. 1. 24.
728x90
반응형