Make sure there is at least one file in it (even just the README.md)
ssh-keygen -t rsa -C "[email protected]"
Make sure there is at least one file in it (even just the README.md)
ssh-keygen -t rsa -C "[email protected]"
| Removing the last commit | |
| To remove the last commit from git, you can simply run git reset --hard HEAD^ | |
| If you are removing multiple commits from the top, you can run git reset --hard HEAD~2 to remove the last two commits. | |
| You can increase the number to remove even more commits. | |
| If you want to "uncommit" the commits, but keep the changes around for reworking, | |
| remove the "--hard": git reset HEAD^ which will evict the commits from the branch and from the index, | |
| but leave the working tree around. |
| const xlsx = require('xlsx') | |
| function excelToJson() { | |
| //read the whole sheet | |
| const sheet = xlsx.readFile('/home/ravi/Desktop/message.xlsx') | |
| //depending on the sheet you want to convert, in my case I wanted the to convert | |
| //first sheet only | |
| const first_sheet = sheet.SheetNames[0] | |
| const sheet1 = sheet.Sheets[first_sheet] | |
| //returns array of object mapped to key pair values dynamically |
| ' Usage: terminator[.vbs] [path to starting directory] | |
| ' contents enclosed in square brackets optional | |
| args = "-c" & " -l " & """DISPLAY=:0 terminator""" | |
| ' If there's a single argument, interpret it as the starting directory | |
| If WScript.Arguments.Count = 1 Then | |
| dir = WScript.Arguments(0) | |
| Else | |
| dir = "" |
| # -*- coding: utf-8 -*- | |
| """ | |
| Created on Tue Sep 1 12:12:18 2020 | |
| @author: Ravi | |
| """ | |
| ''' | |
| Deterministic Selection Algorithm !(one of the coolest linear time algo) | |
| Running Time O(n) {note that not as practical as randomized, cause the constant here is big compare to randomized} | |
| ''' |
| # -*- coding: utf-8 -*- | |
| """ | |
| Created on Mon Aug 31 19:53:34 2020 | |
| @author: Ravi | |
| """ | |
| ''' | |
| Random Selection Algorithm to compute ith order statistic in O(n) time with | |
| high probability, this algorithm is just a made by simple modification of | |
| Quick Sort. If we are very very unlucky then worst case running time = O(n**2) |
| # -*- coding: utf-8 -*- | |
| """ | |
| Spyder Editor | |
| Created on Tue Aug 11 22:37:02 2020 | |
| @author: Ravi | |
| """ | |
| def merge_lists(left_sublist,right_sublist): | |
| #augmentaion starts here | |
| #initialize a inversion count variable to zero |