I apparently don't know how to use the {}code button to format the question and I need help with this 3 variable logical AND operation
3 views (last 30 days)
Show older comments
function andResult = LogicalAND3(inputA, inputB, inputC)
% Assign threeInputAnd with the truth table outcomes for a
% 3 variable logical-and operation
andResult = [inputA], [inputB], [inputC];
end
2 Comments
per isakson
on 11 Oct 2017
Edited: per isakson
on 11 Oct 2017
"I apparently don't know how to use the {}code button to format the question"
The requirements to show a block of text as code are
- the block shall be preceded by an empty line
- each line of the block shall be preceded by two extra spaces
- the block shall be followed by an empty line
The {}Code button adds those extra two spaces and the preceding empty line, but not the closing empty line. Steps
- type the block of text or copy&paste it from the editor
- select the block so that it's displayed in white on a blue background
- push the {}Code button
- make sure there is a closing empty line
Accepted Answer
KSSV
on 11 Oct 2017
function andResult = LogicalAND3(inputA, inputB, inputC)
% Assign threeInputAnd with the truth table outcomes for a
% 3 variable logical-and operation
andResult = inputA & inputB & inputC ;
end
0 Comments
More Answers (0)
See Also
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!