WhiteBox
DSA
Start coding DSA Beyond LeetCode System Design AI Engineering White Room
RoadmapProblem sets
Quizzes Dan Ladder Contests Templates Graph Editor
Guides Library
Login Sign up
Sign up Log in

Workspaces

Start coding DSA Beyond LeetCode System Design AI Engineering White Room

DSA

Overview Roadmap Problem sets Quizzes Dan Ladder Contests Templates Graph Editor CP Guessr

Library

Library Guides

Community

Leaderboard Contributors Refer & Earn Cosmetics

Tools

Resume Reviewer Job Boards Changelog

Basics 0/97

DSA 0 of 360 problems solved
0%
Overview

Curriculum

    1. Loops and simulation 0/17
      1. Basic syntax and I/O 0/10
      2. Simulation 0/7
    2. Time complexity 0/5
    3. Arrays 0/8
    4. Strings 0/7
    5. Stacks and queues 0/8
    6. Complete search 0/29
    7. Recursion 0/13
    8. Sorting and selection 0/10
  1. DSA
  2. / Basics

Start here Loops and simulation · 1 of 2

Basic syntax and I/O

Read a judge's input, print the answer in the layout it expects, write loop bounds that are not off by one, and keep numbers in a type large enough for them.

4,133 words · 19 min read

Lesson Reading4

Books1

  • Competitive Programmer’s Handbook, Chapter 1: Introduction Sections 1.2 and 1.3 cover input and output in C++, the integer types, and the int multiplication that overflows before it is stored. (opens in a new tab)

Links3

  • usaco.guide Input & Output Standard and file input in C++, Java and Python, with a worked solution to CSES Weird Algorithm and how to submit it. usaco.guide (opens in a new tab)
  • usaco.guide Data Types The range of each number type in C++, Java and Python, in one table per language. usaco.guide (opens in a new tab)
  • usaco.guide Fast Input & Output Timings for each way of reading and printing 10^6 numbers, including the 5.8 and 0.41 seconds quoted above. usaco.guide (opens in a new tab)
Lesson: Basic syntax and I/O
Overview Roadmap Problem sets Log in