10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
I would to write the test on one line like :
declare -i x=0 y=0
some code assign value 0 or 1 to x and y
# if either x or y or both is set to 1, then do something
if -o ; then
Any help is welcome (2 Replies)
Discussion started by: jcdole
2. Shell Programming and Scripting
Im trying to write a Bash script that calculates the least common subnet for two address.
Theoretical: I have to change IP from decimal to binary, then apply XNOR on the two IPs.
I tried to write this:
echo "Ebter the first ip"
echo "Enter the second ip"
read... (7 Replies)
Discussion started by: Miron
3. Shell Programming and Scripting
hi, im learning python language. and my teacher gives me this question on class:
Boolean expression :
not (p or not q)
what is the correct answer for that? i still dont understand, and please give me a link for a new beginner in python to learn.
thanks (1 Reply)
Discussion started by: jazzyzha
4. Shell Programming and Scripting
IT seems to be rather small issue, but is not resolved. What Google suggest does no work..!
jobNo=$(awk '/Jobs with... (4 Replies)
Discussion started by: emily
5. Shell Programming and Scripting
Can someone, please, help me to make this condition valid/accepted in bash?
I really cannot.
I'm stuck with the brackets...
This one tells me: missing `]'
if ]; then
# NOTIFY ERROR...
And... I'd also appreciate a link to bash documents that explain these things. All... (2 Replies)
Discussion started by: mamboknave
6. Homework & Coursework Questions
1. The problem statement, all variables and given/known data:
Im experimenting with if expressions for an assignment. What i want to do is check if an input of read x y z will be checked against x for 1-999 for y for and for z for 1-999. Am i doing this right? or perhaps you could tell me... (0 Replies)
Discussion started by: Ren_kun
7. UNIX for Advanced & Expert Users
I was reading this find guide and I saw something with the -and option that I don't think is correct. Do you need the -and option in this?
$ find /mp3-collection -name 'Metallica*' -and -size +10000k I found my file that was bigger than 500 MB with and without the -and option.
~ $ find /... (1 Reply)
Discussion started by: cokedude
8. Shell Programming and Scripting
How can I find out, that whether a regular expression are matched or not(as a boolean)?!
tnx in advance. (2 Replies)
Discussion started by: Zaxon
9. Shell Programming and Scripting
I'm calling an oracle procedure from shell script, this procedure has boolean parameter, the default is false, but I need to pass true value to the procedure... how can I do that in shell script , below is my script:
################ Initialise Environment #################
initialise()... (0 Replies)
Discussion started by: aya_r
10. Shell Programming and Scripting
I have a file coming in with many columns, but the first character of the the coumn is a record type, if I wanted to get a true/false kind of response as to whether it contains at least one of each type of record how would be best?
sed -e '/01/!d; /02/!d; /03/!d; /04/!d' datafile
returns... (4 Replies)
Discussion started by: badg3r