A: Top-posting. Q: What is the most annoying thing on usenet and in e-mail? Jack Klein. Com FAQs for comp. Here is the difference as I see it: Operators are defined as operators by the language. Some operators are overloadable, others are not. Most operators do not create sequence points although when overloaded, the overloaded versions are functions and do impose sequence points.
The number of operands on which an operator operates is fixed and immutable. Other than the fact that functions are overloadable, none of the above applies to them. The concept of "special kind of function" is a very strange one, No, it's not a strange concept, it's the basic idea.
The standard calls it an "operator function" some operator functions can be user-defined. The reader is simply supposed to already have a working notion of what operators are. So clearly an operator mustn't necessarily have a non-alphanumeric name. Victor Bazarov. Ask Question. Asked 9 years, 1 month ago. Active 4 years, 11 months ago. Viewed 6k times. Improve this question.
Val Val 1. I don't think there is a general answer. And in mathematics, I don't think there is a difference. Operators might have a flavour of "higher-order functions" there. I do not think that specialists in some language have a better idea of why they call some thing a function and another operator than answering it in general. So, I ask from computer scientists in general. Add a comment. Active Oldest Votes. Improve this answer.
The history determines the whole realm of machine languages. The distinction is not deep and is language-dependent. Ltf4an Ltf4an 2 2 bronze badges. And, in any case, what does this have to do with the distinction between functions and operators. You are silently applying f x to a value, but as it is written on a page it is another set of symbols.
See Wittgenstein. Wittgenstein wrote quite a bit, so I'm gonna need a specific reference. But "f x " does not.
Get it? Perhaps I'd get it if you actually tried to explain it, instead of making cryptic remarks. MCQ Online Tests Important Solutions Question Bank Solutions Time Tables Advertisement Remove all ads.
Short Note. Solution Show Solution The basic difference between operator function as a friend function and as member function is that a friend function will have only one argument for unary operators and only one for binary operators.
0コメント