/TypeScript-Code-Jam-template

Single file TypeScript template for participate in Google Code Jam

Primary LanguageTypeScript

Google Code Jam TypeScript single file template

I tried to find the easiest way to participate Google Code Jam competition using only TypeScript.

This template heavily depend and use code from @bkolobara stdin-line

Test run

This project use Yarn Zero-Installs. Just clone this repository and it's ready to run.

yarn start

Then you can enter input to process.

Logic change

There're two file. code.ts and code-es2019.ts. The first one written in ES2020 but it can't run in Code Jam 2020 and you should use code-es2019.ts for that. Hoping Code Jam 2021 can run ES2020 in code.ts.

The file already indicate logic area region with caseProcess as async function so you can use async/await or any logic you need. caseProcess return string to log to output as result.

Submit

Just submit code.ts as TypeScript (Node.js) with no need to build or rollup.