#ProblemProblem solving using c

7 messages · Page 1 of 1 (latest)

carmine umbra
#

Problem

person X has two ranges [A, B] and [C, D]. Chef needs to find the number of integers that belong to at least one of the ranges.

Note: A range [P, Q] contains all the integers { P, P + 1, P + 2 ,...,Q-1,Q}

orchid baneBOT
#

When your question is answered use !solved to mark the question as resolved.

Remember to ask specific questions, provide necessary details, and reduce your question to its simplest form. For tips on how to ask a good question run !howto ask.

#
#include __DATE__
We Don't Do Your Homework

Welcome to Together C & C++ 👋

We won't do your homework for you (#rules) but we are happy to help you learn and point you in the right
direction.

Please send what you have so far and ask a specific question.

whole plover
#

<@&847915341954154536> homework

amber parcel
#

!warn @carmine umbra If you're struggling with a homework question, come show what you've done and be specific about where you're stuck. We aren't just going to do your work for you.

bold canopyBOT
#

dynoSuccess Shinigami#4800 has been warned.

tame thorn
#

A) What have you done so far?
B) What exactly do you want to get? Do you want to get all numbers A, A + 1, ..., B - 1, B (or C, C + 1, ..., D - 1, D) or do you just want to get some value x ∈ [A, B] or y ∈ [C, D]?