Skip to content

Instantly share code, notes, and snippets.

View prat0318's full-sized avatar
💭
Ubering on.

Prateek Agarwal prat0318

💭
Ubering on.
View GitHub Profile
@prat0318
prat0318 / Searcher.java
Last active August 29, 2015 14:07
Write a simple search engine which can locate a musical group from the attached dataset and return its url fragment.
import java.util.Scanner;
import java.util.HashMap;
import java.io.BufferedReader;
import java.io.FileNotFoundException;
import java.io.FileReader;
import java.io.IOException;
/* Basically create a cache by pre-processing
the data file. And then it is just a data
@prat0318
prat0318 / merge_sort_list.py
Created October 5, 2014 06:53
Merge sort a linked list
class Node(object):
def __init__(self, val):
self.val = val
self.next = None
def sort(head, tail=None):
if not head:
return None
if head.next == tail:
[15:21] == prat0318 [4812e9bc@gateway/web/freenode/ip.72.18.233.188] has joined #swagger
[15:24] <prat0318> In the petstore's pet resource, path "/pet/uploadImage" ...i want to fix the paramType for 'file' from 'body' to 'form' as per the specs 1.2 ... are the api-docs public, to which i can send a PR?
[15:25] <prat0318> I ask this becuase i have added that validation in my client ..and the petstore example fails that validation prohibiting me from using it as an example. What can i do to fix it?
[15:30] <prat0318> I am referring to : https://github.com/wordnik/swagger-spec/issues/16 .. Can we fix the example?
[16:04] <@tonytam> hi prat0318
[16:04] <prat0318> tonytam: hi
[16:04] <@tonytam> that sample comes from here: https://github.com/wordnik/swagger-core/tree/master/samples/scala-oauth-authorization-server
[16:05] <@tonytam> so the defect is not in the json, it's in the json-generation, which is buried in the server integration
[16:05] == mysterlu_ [~mysterlun@8.25.222.10] has quit [Remote host closed th
@prat0318
prat0318 / prateek_classic.tex
Created July 28, 2014 01:03
Classic template example
% resume.tex
%
% (c) 2002 Matthew Boedicker <mboedick@mboedick.org> (original author) http://mboedick.org
% (c) 2003-2007 David J. Grant <davidgrant-at-gmail.com> http://www.davidgrant.ca
% (c) 2007-2010 Todd C. Miller <Todd.Miller@courtesan.com> http://www.courtesan.com/todd
%
% This work is licensed under the Creative Commons Attribution-ShareAlike 3.0 Unported License. To view a copy of this license, visit http://creativecommons.org/licenses/by-sa/3.0/ or send a letter to Creative Commons, 171 Second Street, Suite 300, San Francisco, California, 94105, USA.
\documentclass[letterpaper,11pt]{article}
cd ~
git clone git@github.com:prat0318/oh-my-zsh.git .oh-my-zsh
git clone git@github.com:prat0318/dotfiles .dotfiles
curl https://raw.githubusercontent.com/Shougo/neobundle.vim/master/bin/install.sh | sh
cd .dotfiles
script/boostrap
source ~/.zshrc
cd ~/.vim/bundle/YouCompleteMe
./install.sh
vi ~/.vimrc
Downloads $ gem install json_resume
Downloads $ json_resume sample
Generated prateek_cv.json in /home/prat0318/Downloads/
You can now modify it and call: json_resume convert <file.json>
Downloads $ json_resume convert prateek_cv.json
Generating the html type...
Generated files present at /home/prat0318/Downloads/resume/page.html
Place /home/prat0318/Downloads/resume/ in /var/www/ to host.
Downloads $
{
"settings": {
"icons" : true
},
"firstname": "Prateek",
"familyname": "Agarwal",
"linkedin_id": "prat0318",
"github_id": "prat0318",
"bio_data": {
"email": "prat0318 @ cs.utexas.edu",

##Prateek Agarwal http://prat0318.github.io prat0318 @ cs.utexas.edu +1 (512) 698-3649

Ruby - Python - Git - Cartooning

###Qualifications summary

  • Competent at managing responsibilities in a high-volume atmosphere
  • Hard worker, quick learner, and ability to assume responsibility

##Prateek Agarwal http://prat0318.github.io prat0318 @ cs.utexas.edu +1 (512) 698-3649

Ruby - Python - Cartooning

Qualifications Summary

  • Competent at managing responsibilities in a high-volume atmosphere
  • Hard worker, quick learner, and ability to assume responsibility

GitHub Projects

class TreeNode
attr_accessor :left
attr_accessor :right
attr_reader :value
def initialize(left, right, value)
@left = left
@right = right
@value = value
end