Search Results

Search: Posts Made By: bigubosu
1,939
Posted By bigubosu
ooh thanks
ooh thanks
1,939
Posted By bigubosu
Difference between 1,$ and /g
just wondering what the difference is between 1,$ and /g when doing a substitution in vi. doesn't seem to be much difference from what i can see.
1,572
Posted By bigubosu
Regular expression on brackets
I'm trying to find matching brackets {[()]}.

but i can't seem to match the inner brackets and print out invalid if it were something like this
([)]
and

()({[]})[]
1,970
Posted By bigubosu
Join command help with spacing
Use and complete the template provided. The entire template must be completed. If you don't, your post may be deleted!

1. The problem statement, all variables and given/known data:
I have to join...
1,734
Posted By bigubosu
I've attempted it though? i'm sooooo close to...
I've attempted it though? i'm sooooo close to getting this but i can't for the life of me see what is wrong.
1,734
Posted By bigubosu
It's what is required for my lab work. I'd gladly...
It's what is required for my lab work. I'd gladly use awk if i could.

i fixed the spacing. but the system i submitting doesn't like it.

sort ${ASS1_DATA_DIR}Prac1 | sed '/^#/d' >...
1,734
Posted By bigubosu
Yeah thats right however i have to join -_-....
Yeah thats right however i have to join -_-. sorry.

Sorry i'm just posting the required output so you know what im trying to get rid of. It's not what im expecting, cause the test data i have...
1,734
Posted By bigubosu
Join help
im trying to join 3 files together


sort -n ${ASS1_DATA_DIR}Prac1 | sed '/^#/d' > ${ASS1_OUTPUT_DIR}Prac1temp
sort -n ${ASS1_DATA_DIR}Prac2 | sed '/^#/d' > ${ASS1_OUTPUT_DIR}Prac2temp
join -a1...
4,319
Posted By bigubosu
nvm i got it working. i added some file checks...
nvm i got it working. i added some file checks and the "./" worked and i could check if the files were there or not even though the environment variable was not listed in the export list.
...
4,319
Posted By bigubosu
I ran it as ./part1
I ran it as ./part1
4,319
Posted By bigubosu
Setting Environment Variables
#!/bin/bash

if [ -z $ASS1_DATA_DIR ]; then
ASS1_DATA_DIR=./
echo $ASS1_DATA_DIR
export ASS1_DATA_DIR
echo "data dir"
fi

if [ -z $ASS1_OUTPUT_DIR ]; then
ASS1_OUTPUT_DIR=./
export...
2,064
Posted By bigubosu
hmm it worked lol. I had to reset my data...
hmm it worked lol.

I had to reset my data though. Let me add more to test it again.

---------- Post updated at 05:30 AM ---------- Previous update was at 05:22 AM ----------

yeah it didn't...
2,064
Posted By bigubosu
oops sorry. I'm not allowed to use cat. I just...
oops sorry. I'm not allowed to use cat. I just used it above so that i would output the result to the screen instead of m opening up the file.

i used
sed '$s/$/\n/g' infile

but i get an extra...
2,064
Posted By bigubosu
Read help
im doing a

while read file
do
<code>

done < file > output

loop.

however i have a list of text with 4 columns each. And i have successfully organised it the way i wanted to the output....
1,866
Posted By bigubosu
Help running scripts in 1 file.
1. The problem statement, all variables and given/known data:
Running different parts of the assignment together in 1 script


2. Relevant commands, code, scripts, algorithms:
awk, nawk, bash,...
1,388
Posted By bigubosu
oh... that should've been something i could've...
oh... that should've been something i could've worked out myself -_-
1,388
Posted By bigubosu
Quick join question
I have to join(no other command is allowed) 3 files together. And im aware that i have to sort these files(file1 file2 file3) first before I can join them.

However i have to output these sorted...
1,090
Posted By bigubosu
Help with running script
So i've done half of my assignment in seperate files. but if i try to run it together then I get a "join: bad interpreter: No such file or directory"

Here are the programs I am allowed to use:...
9,220
Posted By bigubosu
Sorry i should've said that im only supposed to...
Sorry i should've said that im only supposed to do this over 1 line or just as a command. I'm fairly new to using unix tools please forgive me.

so for example listing hte unique words in the file...
9,220
Posted By bigubosu
Counting a particular word per line
1. The problem statement, all variables and given/known data:
It was the best of times, it was the worst of times,
It was the age of wisdom, it was the age of foolishness,
It was the epoch of...
Showing results 1 to 20 of 20

 
All times are GMT -4. The time now is 08:06 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy