All Projects → RameshAditya → Code Faster

RameshAditya / Code Faster

Licence: mit
Sublime Text plugin for programming contests - loads codeforces problems right into your text editor with a single button.

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to Code Faster

Sublimeallautocomplete
Extend Sublime autocompletion to find matches in all open files of the current window
Stars: ✭ 906 (+2284.21%)
Mutual labels:  sublime-text-3, sublime-package
Hayaku
Fuzzy abbreviations, support for preprocessors (Sass, Less, Stylus) and a lot of other features in easily configurable set of tools for writing CSS faster
Stars: ✭ 973 (+2460.53%)
Mutual labels:  sublime-text-3, sublime-package
Sublime-uroboroSQL-formatter
Beautiful SQL Formatter for Sublime Text 3
Stars: ✭ 25 (-34.21%)
Mutual labels:  sublime-text-3, sublime-package
Carbonsublime
🚀 A Sublime Text 3 Plugin for Carbon. (https://carbon.now.sh)
Stars: ✭ 104 (+173.68%)
Mutual labels:  sublime-text-3, sublime-package
AFileIcon
Sublime Text File-Specific Icons for Improved Visual Grepping
Stars: ✭ 192 (+405.26%)
Mutual labels:  sublime-text-3, sublime-package
Sublime Jekyll
A Sublime Text package for Jekyll static sites.
Stars: ✭ 160 (+321.05%)
Mutual labels:  sublime-text-3, sublime-package
SublimeDiscordRP
📄 Discord rich presence for Sublime Text
Stars: ✭ 123 (+223.68%)
Mutual labels:  sublime-text-3, sublime-package
sublime-text-theme-switcher-menu
Painless theme selection in Sublime Text ⚡
Stars: ✭ 18 (-52.63%)
Mutual labels:  sublime-text-3, sublime-package
Sublime zk
A SublimeText3 package featuring ID based wiki style links, and #tags, intended for zettelkasten method users. Loaded with tons of features like inline image display, sophisticated tag search, note transclusion features, support for note templates, bibliography support, support for multiple panes, etc. to make working in your Zettelkasten a joy 😄.
Stars: ✭ 408 (+973.68%)
Mutual labels:  sublime-text-3, sublime-package
sublime-live-server
🌍️ Launch a Development Server directly from Sublime Text
Stars: ✭ 49 (+28.95%)
Mutual labels:  sublime-text-3, sublime-package
Pipenv Sublime
A Sublime Text 3 plugin for Pipenv projects!
Stars: ✭ 65 (+71.05%)
Mutual labels:  sublime-text-3, sublime-package
Chromerepl
A Sublime Text plugin to execute JavaScript in Google Chrome
Stars: ✭ 347 (+813.16%)
Mutual labels:  sublime-text-3, sublime-package
Hugofy Sublime
Hugo plugin for Sublime Text 3
Stars: ✭ 64 (+68.42%)
Mutual labels:  sublime-text-3, sublime-package
Sublime Filterlines
Quickly find all lines matching a string or regular expression
Stars: ✭ 179 (+371.05%)
Mutual labels:  sublime-text-3, sublime-package
Languagetool Sublime
Proof-reading and grammar checker for English, French, German, Polish and 20+ other languages
Stars: ✭ 55 (+44.74%)
Mutual labels:  sublime-text-3, sublime-package
Sublime-Pretty-Shell
🐚 Shell Script Formatter / Syntax Checker (Powered by shfmt)
Stars: ✭ 28 (-26.32%)
Mutual labels:  sublime-text-3, sublime-package
sublime-text
Subime Text 相关资源收集整理
Stars: ✭ 62 (+63.16%)
Mutual labels:  sublime-text-3, sublime-package
CSSFontFamily
CSSFontFamily is a Sublime Text plugin with a collection of font stacks autocomplete.
Stars: ✭ 15 (-60.53%)
Mutual labels:  sublime-text-3, sublime-package
Solarized
Solarized color scheme for Sublime Text 3
Stars: ✭ 314 (+726.32%)
Mutual labels:  sublime-text-3
Dotfiles
i3 + Plasma: using the i3 window manager on the top of KDE Plasma and other dotfiles, configurations, scripts, workarounds and practises from my Debian Sid machines.
Stars: ✭ 651 (+1613.16%)
Mutual labels:  sublime-text-3

Code Faster


A sublime text 3 plugin by Aditya Ramesh

PRs Welcome

What Code Faster is

Code Faster is a Sublime Text 3 Plugin developed with the intent of fetching problem statements directly into the sublime text editor, without needing to open a browser.

What it does

The problem statements are fetched from the Codeforces programming platform (www.codeforces.com) due to their reputation in the field of algorithmic contests. In addition, their API also lent itself well for the purpose of this plug-in.

Set up instructions

Assuming you have Sublime Text 3 set up, head over to C:/Users/{YOUR_USERNAME}/Appdata/Roaming/Sublime Text 3/Packages/

and paste the folder 'Code-Faster-A' in this directory.

You'll also need the python modules urllib, json and BeautifulSoup to get this up and running.

Now, open Sublime Text 3 and along the menu bar, to the right of the Help option, you should notice a new option Codeforces for Adi, and if you do, rejoice!

How it works

How it identifies the contest

Codeforces has a standard template of contest information -> Contest Number + Letter

This pair uniquely defines every question on the platform.

The codeforces API was used to find the current contest number, by requesting for the information of the problems available on the platform and then the ongoing or scheduled contest's number is determined.

The letter (which is usually 'A', 'B', 'C', 'D' or 'E'} is manually entered by the user due to the input restrictions on sublime text plug-ins.

An alternative is to manually hard code 5 separate plug-ins, each that retrieves questions corresponding to different letters of the same contest number. UPDATE: This has been done now, and the "Codeforces for Adi" button now spawns a dropbox wherein the user can select the difficulty level they want a problem statement to be at.

The advantage of using codeforces as the target platform is that the standard problem URL is - codeforces.com/contest_number/letter

How it retrieves the problem statement

The BeautifulSoup module in python, allows for web scraping. Consequently, after acquiring the correct link by leveraging the codeforces API, BeautifulSoup was used to scrape the problem statement off the webpage.

Scope for improvements

  • The parsing of the problem statements of the URL was tedious, and while an alternative would be to remove all the text between every < and > pair, a quick fix was implemented due to lack of time.

  • In addition, it's probably advisable to cache the requests being made as the JSON obtained in response is pretty large in size, and in runtime requires ~ 3-4 seconds to work.

  • A creative fix to minimize fetching time would be, to replace calling all the current information of the problems on the platform, and use their API to call just the most recent submissions, as during a live contest, majority of the audience on the platform will actively be submitting solutions of the same contest.

Future Plans

  • Fix the HTML tag parsing issue. I have gotten a lead! This will solve the issue of LaTeX tags and even images, yes, images in Sublime Text is possible. I am currently working on this, and will update the repo once I've made considerable progress.
  • Handle questions with embedded images - either automate the opening of the images alone in a browser, or directly open the same question in a browser due to lack of image support in- well, text editors. UPDATE: This has now been done -- upon scraping the problem statement, if an image exists, Python's Selenium module is leveraged to retrieve the image URL and is opened in a new Firefox window.
  • Allow users to submit their solutions to the corresponding links (from within Sublime Text 3)
  • Incorporate Machine Learning Algorithms to parse through user's submission history, and perform analysis of his submitted solutions, and pull recommended questions for the user to learn faster.
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].