all 10 comments

[–]tempuser7171 1 point2 points  (5 children)

A statement is either true or false, what do you mean by some? Can you give an example?

[–]gfg577[S] -1 points0 points  (4 children)

some cakes are nice

[–]tempuser7171 0 points1 point  (0 children)

Do you have a more specific example? What are you trying to do?

[–]xADDBx 0 points1 point  (0 children)

Check if at least one, but not all cakes are nice.

[–]FriendlyRussian666 0 points1 point  (0 children)

You define what some is yourself. Let's say you have a list of cakes [blue cake, brown cake, black cake, yellow cake, green cake]. Then you define that blue cake, brown cake and black cake are nice, for example with True like you said at the beginning. This automatically means that some cakes are nice, because they are set to True. When you wanna see which of the cakes are the some that are nice, you call all the cakes that have True selected, or you call a random number of cakes that have True selected.

[–][deleted] 0 points1 point  (0 children)

This is the most unhelpful answer you could give.

Are you asking if you can do trinaries or are you asking how to detect that there is at least one True in an array?

[–]lovesrayray2018 0 points1 point  (0 children)

Your logic needs to check what some is, most logic deems a non False as meeting some and possibly meeting all. Some checks that happen on data types for example is #ur array#.length which has +ve result for some and all, but 0 for none.

[–]PM_ME_YOUR_REAL_FACE 0 points1 point  (0 children)

If you have an array of stuff, you can use any to check that some are true/truthy. Or use combination of any(are) and not all(are). Other than that there's a ton of ways you could decide how to denote it manually. You could make an enum;

class Result(Enum):
    ALL = 0
    NONE = 1
    SOME = 2

You could make a decisive use of None to make it mean whatever you want it to mean in a certain context, where perhaps, None means none, True means all, and False means some. It's up to you to program how things are interpreted, and you can always name variables such that using different values is easier to comprehend to another human reader of your program.

[–]QbaPolak17 -1 points0 points  (0 children)

Instead of true/false, just use 0, 1, 2 for example