Count the number of heads and tails using the sum function with logical indexing.
Info
This question is closed. Reopen it to edit or answer.
Show older comments
The number of coin flips is 100. How do I count the number of heads and tails using the sum function with
logical indexing? Divide each count by n to get the proportion of heads and tails.
1 Comment
Dyuman Joshi
on 2 Mar 2024
What have you attempted yet?
Answers (0)
This question is closed.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!