Awk

Print Specific Columns (separator=:): awk -F':' '{print $1, $3}' file.txt `` Filter Lines Based on a Condition: awk '$3 > 50 {print $1}' file.txt Condition awk '{if ($1 > 10) print "Greater"; else print "Lesser"}' file.txt Pattern Awk operates based on patterns and associated actions. If a pattern matches a record, the associated action is executed. If no pattern is specified, the action is applied to all records. For example, to print lines containing the word “hello”:...

July 2, 2023 · 2 min · Erotourtes

Docker

Architecture Container - is a process, which has it’s own file system Docker depends on Kernel Recap When we ran a container and doesn’t interact with it, the container simply stopps Commands docker pull ubuntu # downloads an image docker run ubuntu # ducker pull & docker run docker run -it ubuntu # interactive mode Show List docker ps -a # all containers docker image ls (or docker images) # all images Build docker build -t <name>:version ....

May 26, 2023 · 4 min · Erotourtes

Network

Theory For more info Site Drive Протокол рівня n - правила та домовленості, які використовуються для взаємодії рівня n одного вузла з рівнем n іншого вузла Інтерфейс - правила взаємодії суміжних рівнів в одному вузлі Протокол - це горизонтальна взаємодія (між своїми протоколами передачі даних) Інтерфейс - vertical communication (between protocols from different levels) ISO OSI The ISO company (1983) made an Open System Interconnection Reference Model(OSI) It is open specification....

May 8, 2023 · 12 min · Erotourtes

Bash

Varibales NAME=Hello without any spaces To make it global export NAME=WORLD Comands head tail -f cut -d" , " -f 2 file.name uniq sort tr sed ‘regex’ name.txt wc - shows number of lines words characters Streams 0 Stdin 1 Stdout 2 Stderr Redirect > to a file >> append if exists 2> redirect error &> stdout and stderr < std in <> std in from file and redirect to it...

September 19, 2022 · 2 min · Erotourtes

RegEx

Regular expressions

September 16, 2022 · 1 min · Erotourtes

Data structures and algorithms

Recap algorithms

August 22, 2022 · 8 min · Erotourtes

Java basics

Created with Mosh Theory JVM Java code compiled to Bytecode than jvm convertes it to native code for platform Boxing When Primitive types convertes to Reference public static void method(Integer value) {} public static void main(String[] args) { method(1); //boxed int into Integer } Unboxing When Reference types convertes to Primitive public static void method(int value) {} public static void main(String[] args) { method(Integer.valueOf(1)); //unboxed Integer into int } Casting Implicit casting short a = 1; int b = a + 1; Explicit casting double a2 = 1....

August 21, 2022 · 5 min · Erotourtes

TODO

List of to-do

2 min · Erotourtes