python (12.9k questions)
javascript (9.2k questions)
reactjs (4.7k questions)
java (4.2k questions)
java (4.2k questions)
c# (3.5k questions)
c# (3.5k questions)
html (3.3k questions)
Removing array entries from lastlog command bash
I am running a command in a script which saves usernames in an array and I was wondering if there is a simple solution to removing these usernames during a run of the lastlog command.
I was thinking o...
Nixbest
Votes: 0
Answers: 1
how-to save result of a command in an if statement to a text file
I need to do something like:
while true
do
if ss --tcp --processes | grep 53501 ; then <save result to /tmp/cmd.out> ; fi
done
user11236651
Votes: 0
Answers: 2
Count the number of times a substring appears in a file and place it in a new column
Question:
I have 2 files, file 1 is a TSV (BED) file that has 23 base-pair sequences in column 7, for example:
1 779692 779715 Sample_3 + 1 ATGGTGCTTTGTTATGGCAGCTC
1 783462 783485 Sample_4 - 1 ATGA...

KLM117
Votes: 0
Answers: 3
Logic for implementing GNU's grep -A -B -C flag
I am trying to implement the logic behind grep's -A -B -C flags. To understand how things work, I have cloned the grep C code and looked into it too. But I am not good with C so I am finding it very d...
Raaz
Votes: 0
Answers: 2