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
# Enable Powerlevel10k instant prompt. Should stay close to the top of ~/.zshrc. | |
# Initialization code that may require console input (password prompts, [y/n] | |
# confirmations, etc.) must go above this block; everything else may go below. | |
if [[ -r "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" ]]; then | |
source "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" | |
fi | |
# If you come from bash you might have to change your $PATH. | |
# export PATH=$HOME/bin:/usr/local/bin:$PATH |
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
#!/bin/bash | |
node_v=$1 | |
if [ -z "$1" ] | |
then | |
echo "Using default stable version 16.x" | |
node_v="16" | |
fi |
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
public class MoveZeroesWithOutOrder { | |
public static void main(String[] args) { | |
int[] arr = {0, 1, 0, 3, 12}; | |
moveZeroes(arr); | |
for (int num : arr) { | |
System.out.print(num + " "); | |
} | |
System.out.println(); | |
} |
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
# syntax=docker/dockerfile:1 | |
FROM python:3.7-alpine | |
WORKDIR /code | |
RUN apk add --no-cache gcc musl-dev linux-headers | |
COPY ./requirements.txt requirements.txt |
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
#!/bin/bash | |
## Run after kubeadm init | |
mkdir -p $HOME/.kube | |
sudo cp -i /etc/kubernetes/admin.conf $HOME/.kube/config | |
sudo cp -i /etc/kubernetes/admin.conf $HOME/admin.conf |
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
#!/bin/bash | |
## Reset kube | |
sudo kubeadm reset | |
## Remove kube configs | |
sudo rm -rf /etc/kubernetes/kubelet.conf |
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 java.util.Objects; | |
public class Solution { | |
public static void main(String[] args) { | |
int[] arr1 = {1, 20, 3, 4, 2}; | |
int[] arr2 = {1, 70, 900, 445, 5}; | |
int[] result = mergeWithOutDuplicates(arr1, arr2); | |
for (int i : result) { |
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
[Desktop Entry] | |
Encoding=UTF-8 | |
Version=1.0 | |
Type=Application | |
Name=Postman | |
Icon=/opt/Postman/app/resources/app/assets/icon.png | |
Path=/opt/Postman | |
Exec=/opt/Postman/Postman | |
StartupNotify=false | |
StartupWMClass=Postman |
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
public class Main { | |
public static void main(String[] args) { | |
QueueUsingArray queue = new QueueUsingArray(); | |
System.out.println(queue.isFull()?"Full":"Not Full"); | |
System.out.println(queue.isEmpty()?"Empty":"Not Empty"); | |
queue.enQueue(11); | |
queue.enQueue(101); | |
queue.enQueue(1111); |
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
class Main { | |
public static void main(String[] args) { | |
Stack stack = new Stack(); | |
System.out.println(stack.isEmpty() ? "Empty" : "Not Empty"); | |
stack.push(12); | |
stack.push(13); | |
System.out.println("Find 14 : Found At Index " + stack.search(14)); | |
stack.push(14); | |
stack.push(15); |
NewerOlder