Skip to content

Instantly share code, notes, and snippets.

View lakpahana's full-sized avatar

AGS Lakpahana lakpahana

View GitHub Profile
#!/usr/bin/python3
"""
created by :
Nityananda Gohain
School of Engineering, Tezpur University
27/10/17
"""
@lakpahana
lakpahana / alive.txt
Created February 22, 2024 16:30
200 REASONS YOU NEED TO STAY ALIVE!
saw this in a utube comment.
reasons to stay alive 🤍
1. your family
2. your friends
3. the feeling you get when you’ve finished something
@lakpahana
lakpahana / gist:28ffe7f6515736c1c18a4c2353d1d973
Created August 19, 2023 05:39
CVV add slash and validation
function formatString(e) {
var inputChar = String.fromCharCode(event.keyCode);
var code = event.keyCode;
var allowedKeys = [8];
if (allowedKeys.indexOf(code) !== -1) {
return;
}
event.target.value = event.target.value.replace(
/^([1-9]\/|[2-9])$/g, '0$1/' // 3 > 03/
@lakpahana
lakpahana / gist:518767ae0496a6ca316ff9d9775c8c72
Created August 3, 2023 03:57
How To Read A STRING Line In C++
#include <string>
#include <sstream>
string line;
getline(cin, line);
istringstream iss(line);
string word;
while (iss >> word)
{
In case you cannot download node packages using uni wifi.
Open cmd and run following two commands.
npm config set https-proxy http://10.50.225.222:3128
npm config set proxy http://10.50.225.222:3128
When you switch back to your private connection. Run following two commands.
npm config delete proxy
npm config delete https-proxy
using System;
using System.IO;
namespace ConsoleApp4
{
class MyClassCS
{
static void Main()
{
using var watcher = new FileSystemWatcher(@"C:\xampp\htdocs\FileSystemWatcher");