Skip to content

This repository contains template for implementation of various algorithms for use in competitive programming.

Notifications You must be signed in to change notification settings

UtsavUpadhyay08/CP_Algorithms

Repository files navigation

Execution with Input and Output Files

To run the compiled C++ program with input from a text file and store the output in another text file, follow these steps:

  1. Compile the C++ file:

    g++ <path_to_cpp_file> -o <output_executable_name>

    Example:

    g++ ./codeforces_sol.cpp -o ./codeforces_sol
  2. Run the program with input and output redirection:

    <output_executable_name> < <path_to_input_file> > <path_to_output_file>

    Example:

    ./codeforces_sol < ./input.txt > ./output.txt

    This will run the program with input.txt as the input file and save the output to output.txt.

About

This repository contains template for implementation of various algorithms for use in competitive programming.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages