Menu
Menu
DaniWeb
Log In
Sign Up
Read
Contribute
Meet
Search
Search
About 1,000 results for
logical_operators
- Page 1
Re: 💻 What’s the First App You Install on a Fresh Windows Machine?
Hardware and Software
Microsoft Windows
1 Month Ago
by Reverend Jim
As is typical with Microsoft, their search/find tools work poorly, can hog resources, and are difficult to use. "Everything Indexer" is easy to use, has a small footprint, and has almost no effect on my resources. Search queries show you results as you type, and you can create complex search terms with logical operators, as opposed to the…
Re: Any jQuery 4 users?
Programming
Web Development
2 Months Ago
by jkon
I'm still using jQuery, a very slim build. Our JS library/framework handles all the heavy lifting, including AJAX, WebSockets, logical events, data manipulation, and architectural events. Replacing jQuery would be relatively easy since we often use our own extended jQuery functions, like our custom 'onClick' (which has a different implementation in…
Logical operators to perform Operations in SAP HANA
Programming
Databases
6 Years Ago
by karansingh
I am facing issues using logical operators to perform operations in SAP HANA. Can anyone help me?
Re: difference between bitwise and logical operators
Programming
Software Development
13 Years Ago
by CPT
someone correct me if I'm wrong: both bitwise and logical operators are the representation of the boolean function with the same names(better read on that first as I suspect the fact that you haven't) the diference is that the bitwise ones operate on bits(it doesn't matter if your data type has 8,16,32 or 64 bits, the operation is applied to every …
Diff b/w logical operators and bitwise operators...?
Programming
Software Development
17 Years Ago
by web_master
i know how we can use logical operators.....but how do we use bitwise operators.....
Re: difference between bitwise and logical operators
Programming
Software Development
13 Years Ago
by GeekTool
>>hello everyone, Whats the difference when your using bitwise operators and logical operators in a conditional statements? Bitwise Example: if ((val==1)|(val==2)) printf("%d\n",val); else printf("False"); Logical Example: if ((val==1)||(val==2)) printf("%d\n",val); else …
Shift-Add vs Multiplication // Bit-Wise vs. Logical Operators
Programming
Software Development
14 Years Ago
by ceatkin2
I am trying to demonstrate to my class mates the run time difference in using bit-wise and logical operators. I chose to do this by writing a simple (I thought) program that reads 2 ints from the console, and multiplies them two separate times, one using the logical multiply (a * b) and one using a shift-add algorithm. However, I am stumped in …
Re: difference between bitwise and logical operators
Programming
Software Development
13 Years Ago
by JamesCherrill
^ basically right, except that nowhere does Java define any mapping between 0 and 1s vs the boolean values false/true. Bitwize operators work on each bit of an int value, the logical operators work on individual boolean true/false values, but there's no connection between these two versions.
difference between bitwise and logical operators
Programming
Software Development
13 Years Ago
by GeekTool
>> I googled the dinference between bitwise and logical operators, but i could not understand exactl what it is. Can you simply explain ?
Re: Bitwise and Logical Operators
Programming
Software Development
13 Years Ago
by TrustyTony
pre increment is done before actual execution in surrounding statement, it is done by putting the two plusses before the statement. If the operation is bitwise, the increment happens in every case and age is allways increased by one. But here with shortcutting kind logical operators, the value of age would only happen if birthday is set: …
Re: Bitwise and Logical Operators
Programming
Software Development
13 Years Ago
by GeekTool
> pre increment is done before actual execution in surrounding statement, it is done by putting the two plusses before the statement. If the operation is bitwise, the increment happens in every case and age is allways increased by one. But here with shortcutting kind logical operators, the value of age would only happen if birthday is set: &…
Logical Operator Confusion
Programming
Software Development
11 Years Ago
by DeadH34d
I've been reading through this introductory book on Python, and I've been following along fairly well. Compared to C++, Python seems to make more sense to me. That is, until I reached a section on Logical Operators. I don't completely understand what I just typed in to IDLE, and the results that were returned. Here's what I read: Python …
Logical Operator help
Programming
Software Development
19 Years Ago
by asatrujesus
Im reading about logical operators (yes noob here) and Im sort of confused as to what some of them actually mean. Example: if b1 is true and b2 is false !(b1 & b2) is true b1 | b2 is true b1 & b2 is false b1 ^ b2 is true i know that: & is AND | is OR ! is NOT ^ is XOR But the question is what do the above …
Re: Logical Operator help
Programming
Software Development
19 Years Ago
by freesoft_2000
Hi everyone, See the below two links [url]http://www.cafeaulait.org/course/week2/45.html[/url] [url]http://www.sap-img.com/java/java-boolean-logical-operators.htm[/url] I hoped that helped you Yours Sincerely Richard West
Re: Diff b/w logical operators and bitwise operators...?
Programming
Software Development
17 Years Ago
by Prabakar
Search the forum first, many threads are there on bitwise operators
Re: difference between bitwise and logical operators
Programming
Software Development
13 Years Ago
by NormR1
Where are the definitions of the two types of operators you were asking about?
Re: difference between bitwise and logical operators
Programming
Software Development
13 Years Ago
by NormR1
Can you post what you have found and your questions about what you don't understand? The logical operator returns a true/false value like == or < bitwise changes the value of a variable like a + or * operator
Re: Logical operators to perform Operations in SAP HANA
Programming
Databases
6 Years Ago
by rproffitt
That's an overly broad question. But if it was true, tell me without spamming what courses you completed on this product. It's strange to be thrown into SAP without training so let's here more about what happened to land you this job.
Re: logical operators applied to a double
Programming
Mobile Development
9 Years Ago
by deceptikon
> This code was coverted from VB by simply replacing the 'And's and 'Or's. One thing to note is that these are not comparable operators. `And` and `Or` are not short circuiting in VB, yet `&&` and `||` are in Java. Whether this is relevant depends heavily on your logic, but it's a point that needs to be made. `&&` and `||` are …
Beginner's Tutorial on Operators
Programming
Software Development
11 Years Ago
by Learner010
# Tutorial On Operators# *Operators are the signs to the tell the compiler to perform specific task*. The Operators fall into following categories :- Arithmatic Operator Relational Operator Logical Operator Bitwise Operator Miscellaneous Operator(i added Assignment Operators in this categeory) **Arithmatic operators:-** …
need some help in java operators.
Programming
Software Development
13 Years Ago
by Johnstep
Hi guys, I need some help in this exercises here are the given problems. A. Create a program using arithmetic operators. Use JOptionPane for input of any four variables. B. Create a program using relational operators. Use java.util scanner for input of any three variables. C.Create a program using Logical operators. Use Scanner and for …
Bitwise operators/ undefined and implementation-defined?
Programming
Software Development
18 Years Ago
by JoBe
Hello ladies and gents, Gotta few questions if you don't mind: 1) Exc_6_4) Wrote a table of values for the bitwise logical operators and was wondering if any of you could check them out whether they are correct this way. 2) I have to write five examples of undefined behaviour and five examples of implementation-defined behaviour. I'm I …
How to add data (logical operator) recursively in a binary tree
Programming
Software Development
13 Years Ago
by jkembo
I am stuck, I know how binary tree works, but I don't have any clue how to add data recursively in a binary tree. The user needs to enter a formula with logical operators. If the user presses to a button e.g NOT(unary operator), then it should display at follow : NOT(...) Then instead of the 3 dots the user can enter manually a letter "b&…
Bitwise and Logical Operators
Programming
Software Development
13 Years Ago
by GeekTool
> I have asked this question before, but i think i could not totally understand the diffefence between bitwise and logical operands. According to the book i am using to learn java, the bitwise operands can change the value and this is described as side effect. Also, in bitwise operands, both of the sides are evaluated. that means they don't …
Re: Bitwise and Logical Operators
Programming
Software Development
13 Years Ago
by GeekTool
> Yes it means just that, and because the increment is pre-increment, it means same time and that age was 64 or more before if the condition was true. I could not understand what you mean by pre-increment, what if the statement was &. Then if it was nto the birthday, the age would not increase by 1. ( also age is supposed to be more or …
Re: Shift-Add vs Multiplication // Bit-Wise vs. Logical Operators
Programming
Software Development
14 Years Ago
by N1GHTS
Let me get this straight. So you want to prove to your peers that one technique is faster than the other, yet you are having trouble making the technique you are bragging about function correctly? Maybe its because the technique is flawed. You see, multiplication in C using the multiplication operator '*' gets converted to something like this: [b…
Re: Shift-Add vs Multiplication // Bit-Wise vs. Logical Operators
Programming
Software Development
14 Years Ago
by N1GHTS
I just want to add that there are add-shift's that you can do with specific kinds of numbers which have less clock cycles than [COLOR="Red"]MUL[/COLOR] (like mulitplying by 2 is faster just doing [COLOR="Red"]SHL[/COLOR]) and on some processors, [COLOR="Red"]MUL[/COLOR] is very slow compared to alternative ASM code, …
Re: Shift-Add vs Multiplication // Bit-Wise vs. Logical Operators
Programming
Software Development
14 Years Ago
by ceatkin2
I wouldn't say I was bragging about the idea as much as my professor gave my the assignment to write a program that demonstrates the run-time of each method. I agree it's trivial, but I would still like to know the logic. So, just to be clear, I'm looking for a way to multiply any two ints just using shifts and adds. It shouldn't be more than 1 or …
Re: Shift-Add vs Multiplication // Bit-Wise vs. Logical Operators
Programming
Software Development
14 Years Ago
by N1GHTS
[code] int mul(int x, int y) { int r = 0; for (;y!=0;y>>=1,x<<=1) if (y&1) r+=x; return r; } [/code] I would love to know if you or someone else could recode this so that it does less work.
Re: Shift-Add vs Multiplication // Bit-Wise vs. Logical Operators
Programming
Software Development
14 Years Ago
by ceatkin2
Nights, thanks for your help, I truly appreciate it. However, I ran the code you supplied and it doesn't multiply the two numbers to get the correct result. I've fiddled around with the numbers and it seems that the answer it throws is half off from the actual answer.
1
2
3
17
Next
Last
Search
Search
Forums
Forum Index
Hardware/Software
Recommended Topics
Programming
Recommended Topics
Digital Media
Recommended Topics
Community Center
Recommended Topics
Latest Content
Newest Topics
Latest Topics
Latest Posts
Latest Comments
Top Tags
Topics Feed
Social
Top Members
Meet People
Community Functions
DaniWeb Premium
Newsletter Archive
Markdown Syntax
Community Rules
Developer APIs
Connect API
Forum API Docs
Tools
Backlink Auditor
Legal
Terms of Service
Privacy Policy
FAQ
About Us
Advertise
Contact Us
© 2025 DaniWeb® LLC