Skip to content

Instantly share code, notes, and snippets.

View Prajwalprakash3722's full-sized avatar

Prajwal prakash Prajwalprakash3722

View GitHub Profile
@Prajwalprakash3722
Prajwalprakash3722 / netflix_history.go
Created September 14, 2023 20:47
Count the number of Series & Movies you have watched, Download the NetflixViewingHistory from your account/profile
package main
import (
"encoding/csv"
"fmt"
"os"
"regexp"
)
func main() {
@Prajwalprakash3722
Prajwalprakash3722 / VagrantFile
Last active August 7, 2023 16:35
2 ubuntu 22.04 os
# -*- mode: ruby -*-
# vi: set ft=ruby :
Vagrant.configure("2") do |config|
config.vm.box = "generic/ubuntu2204"
config.vm.network "private_network", type: "dhcp"
(1..2).each do |i|
config.vm.define "ubuntu#{i}" do |node|
node.vm.provider "libvirt" do |vb|
@Prajwalprakash3722
Prajwalprakash3722 / VagrantFile
Created August 5, 2023 08:14
Init VagrantFile
# -*- mode: ruby -*-
# vi: set ft=ruby :
# All Vagrant configuration is done below. The "2" in Vagrant.configure
# configures the configuration version (we support older styles for
# backwards compatibility). Please don't change it unless you know what
# you're doing.
Vagrant.configure("2") do |config|
# The most common configuration options are documented and commented below.
# For a complete reference, please see the online documentation at
import java.util.Iterator;
class Node {
int value;
Node node;
}
public class Solution {
public static void main(String[] args) {
@Prajwalprakash3722
Prajwalprakash3722 / llvm-building.md
Last active July 27, 2023 15:09
llvm-building.md

Compiling LLVM from source is mandatory if you are developing an in-source pass (within LLVM source tree). For example, a debug build of LLVM is much more pleasant to work with compared to an optimized one. To compile LLVM, please follow the following steps:

  1. Download LLVM source and unpack it in a directory of your choice which will refer to as [LLVM_SRC]

  2. Create a Seperate Build folder in your choice of directory

$ mkdir llvm-build
$ cd llvm-build
package main
import (
"fmt"
"math/rand"
"sync"
"time"
)
// Course struct
@Prajwalprakash3722
Prajwalprakash3722 / sql.js
Created March 30, 2023 08:25
For Migrating Alumini Data to SQL Statements
const sids = {
main: 0,
compsoc: 1,
comsoc: 2,
pes: 3,
aps: 4,
sps: 5,
ras: 6,
wie: 7,
sight: 8,
@Prajwalprakash3722
Prajwalprakash3722 / script.py
Created March 30, 2023 08:24
For Migrating Execom Data to SQL Statements
import json
# load the data from the JSON file
with open('execom.json') as f:
data = json.load(f)
# define the sids mapping
sids = {
'main': 0,
'compsoc': 1,
controller.onabort = () => { window.alert('The network request was cancelled.')};
axios.get(`api.example.com/endpoint`,{
signal: controller.signal,
})
.then((response: any) => {
// handle data
})
.catch(() => {
// handle failure
});