Skip to content

Instantly share code, notes, and snippets.

View rlingineni's full-sized avatar
💭
building cool stuff

Raviteja Lingineni rlingineni

💭
building cool stuff
View GitHub Profile
@rlingineni
rlingineni / index.html
Last active October 22, 2019 02:10
Semantic UI Hello World
<!DOCTYPE html>
<html>
<script src="js/semantic.min.js"></script>
<link rel="stylesheet" type="text/css" href="css/semantic.min.css">
<head>
<title>Hello World!</title>
</head>
<body>
@rlingineni
rlingineni / index.js
Last active May 15, 2021 21:43
Signed Cookie Auth in AWS Lambda
"use strict";
const AWS = require('aws-sdk');
const serverless = require('serverless-http');
const Koa = require('koa');
const Router = require('koa-router');
const crypto = require('crypto');
const bodyParser = require('koa-bodyparser');
const fs = require("fs");
const app = new Koa();
@rlingineni
rlingineni / output.v
Last active November 19, 2017 05:42
Verilog output
time clk Clear State Operation GreenLight RedLight Complete
0 0 0 xx Pressed: x x x x
10 1 1 00 Pressed: x x x 0
20 0 1 00 Pressed: x x x 0
TRYING INVAVLID CODE
30 1 0 00 Pressed: x x x 0
40 0 0 00 Pressed: 3 x x 0
50 1 0 00 Pressed: 3 x x 0
60 0 0 00 Pressed: 3 x x 0
70 1 0 01 Pressed: 3 x 1 0
module testMul3 ;
reg [7:0] in ;
reg error ;
wire out ;
Multiple_of_3 dut(in, out) ;
initial begin
in = 0 ; error = 0 ;
@rlingineni
rlingineni / event.json
Created August 28, 2017 17:40
AWS Lambda Proxy Event
{
"message": "Hello me!",
"input": {
"path": "/test/hello",
"headers": {
"Accept": "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8",
"Accept-Encoding": "gzip, deflate, lzma, sdch, br",
"Accept-Language": "en-US,en;q=0.8",
"CloudFront-Forwarded-Proto": "https",
"CloudFront-Is-Desktop-Viewer": "true",
@rlingineni
rlingineni / rock_collect.py
Created August 16, 2017 18:22
Dr.Chrono Rock_Collection Python
# Complete the function below.
def get_rock_index(quantity):
jamie = quantity
print jamie
ned = list(quantity)
ned.sort()
print ned
geoffrey = []
@rlingineni
rlingineni / Job.Java
Created April 26, 2017 22:36
Java implementation of a ShortestRemainingScheduler that takes in a list of Jobs
public class Job {
public Job(String n, int e, int d)
{
name = n;
entryTime = e;
duration = d;
serviceTime = duration;
}
@rlingineni
rlingineni / scheduler.java
Created April 16, 2017 01:31
Scheduling Algorithm driver
import java.io.FileNotFoundException;
import java.io.FileReader;
import java.util.ArrayList;
import java.util.List;
import java.util.Scanner;
public class Scheduler {
public static void main(String args[]) throws FileNotFoundException
{
<?xml version="1.0" encoding="UTF-8"?>
<ContentPage xmlns="http://xamarin.com/schemas/2014/forms" xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml" x:Class="Sample.HelloWorldPage"
BackgroundColor= "Black">
<ContentPage.Content>
<ScrollView>
<Grid RowSpacing="5">
<Grid.RowDefinitions>
<RowDefinition Height="*" />
@rlingineni
rlingineni / Parent.java
Created February 25, 2017 04:03
Reading a Stream in Java
StringBuilder sb = new StringBuilder();
Runtime rt = Runtime.getRuntime();
//You need to use this!
String current = System.getProperty("java.class.path");
System.out.println("Current dir:"+current);
//Make sure to use -classpath flag
Process proc = rt.exec("java -classpath " + current + " Memory");