This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# India | |
# delhi: With a population of 33,807,403 as of 2024. | |
# mumbai: With a population of 21,673,149 as of 2024. | |
# kolkata: With a population of 15,570,786 as of 2024. | |
# Somalia | |
# mogadishu: With a population of 2,587,183 as of 2024 | |
# hargeisa: With a population of 1,176,617 as of 2024 | |
# bossaso: With a population of 615,067 as of 2024 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Reference: https://stackoverflow.com/a/70599253 | |
[ | |
{ | |
"key": "ctrl+up", | |
"command": "cursorMove", | |
"args": { | |
"to": "up", | |
"by": "line", | |
"value": 10 | |
}, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let selectDropDownActive = false; | |
let selectDropDownActiveItem = null; | |
$(window).blur(function() { | |
BlurActiveSelectBox(); | |
}) | |
$('select').click(function() { | |
if (selectDropDownActiveItem != this) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import asyncio | |
def SendEmail(email, subject, message): | |
import threading | |
t = threading.Thread(target=SendEmailThread, args=(email, subject, message)) | |
t.start() | |
def SendEmailThread(email, subject, message): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <bits/stdc++.h> | |
using namespace std; | |
void PrintVector(vector<int> vec){ | |
int n = (int) vec.size(); | |
for(int i = 0; i < n; i++){ | |
cout << vec[i] << " "; | |
} | |
cout << endl; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include<bits/stdc++.h> | |
using namespace std; | |
class Node { | |
public: | |
int data; | |
Node *left; | |
Node *right; | |
Node(int d) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include<iostream> | |
#include<vector> | |
using namespace std; | |
int print_vector(vector<int> arr){ | |
for(int i = 0; i < (int) arr.size(); i++){ | |
cout << arr[i] << " "; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include<stdio.h> | |
#include<stdlib.h> | |
int main(int argc, char *argv[]){ | |
int rows = 3; | |
int cols = 3; | |
// allocate memory to store pointers which point to each row | |
int** matrix = (int **) malloc(rows * sizeof(int *)); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const functions = require('firebase-functions'); | |
const AWS = require('aws-sdk'); | |
var https = require('https'); | |
const cors = require('cors')({origin: true}); | |
AWS_ACCESS_KEY = "aws-access-key-goes-here"; | |
AWS_SECRET_KEY = "aws-secret-key-goes-here"; | |
BUCKET_NAME = "bucket-name-goes-here"; | |
const s3 = new AWS.S3({ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Javascript | |
// Using node-vad | |
floatingPointArray = [...]; | |
let buf = Buffer.allocUnsafe(4 * floatingPointArray.length); | |
for (var k = 0 ; k < floatingPointArray.length ; k++) { | |
buf.writeFloatLE(floatingPointArray[k], k * 4); | |
} |
NewerOlder