frankcollins3 / fcc-mcsft-cSharp

FreeCodeCamp & Microsoft C# course:
1 stars 0 forks source link

string being understood as bool ? [11:26pm] #11

Closed frankcollins3 closed 1 year ago

frankcollins3 commented 1 year ago

attempting to do: string[].Split() an SKU/product code and make case patterns based on different potential cases convert if statement to boolean

Screen Shot 2023-09-07 at 11 30 47 PM

error: Screen Shot 2023-09-07 at 11 24 24 PM

proposed approach: ?

frankcollins3 commented 1 year ago

first step commenting out code so that only the first product[0] is handled. not product[1] && product[2]; [11:27am]

frankcollins3 commented 1 year ago

skipped ahead to look at code. need multiple switch statements. each switch statement corresponds to a separate array index of the split product SKU [11:31am]

frankcollins3 commented 1 year ago

// could've spent more time guessing less time learning. [11:31pm]