notelliottcable has quit [Ping timeout: 255 seconds]
PragCypher has quit [Quit: Leaving]
yorick has quit [Remote host closed the connection]
<micahjohnston_> hey, voiceless velar fricatives!
<alexgordon> sup micahjohnston_
<micahjohnston_> hi alexgordon
<micahjohnston_> i love phonological terms
<alexgordon> micahjohnston_: have you read about korean?
<micahjohnston_> alexgordon: yeah I used to know hangul
<micahjohnston_> forgot a lot of it but
notalexgordon has joined #elliottcable
alexgordon has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
abumirqaan is now known as muqayil
<purr> <purr> elliottcable: a box of lights
sephr has quit [Quit: Leaving]
<micahjohnston_> elliottcable: I always arrive right after you leave :(
<purr> <Nuck> when the fuck was I a seahorse
<Nuck> ... when the fuck did I say that?
cloudhead has joined #elliottcable
cloudhead is now known as Guest57315
<purr> <alexgordon> like a place for really religious salmon to go
<purr> <elliottcable> I’mma name my first child SIGWINCH.
alexgordon has joined #elliottcable
<purr> <darkf> im not math you should know that
Guest57315 has quit [Ping timeout: 260 seconds]
sephr has joined #elliottcable
<purr> <elliottcable> !nautical themed pashmima afghan
<elliottcable> hi!
<elliottcable> micahjohnston_!
sephr has quit [Read error: Connection reset by peer]
sephr has joined #elliottcable
<alexgordon> elliottcable!
<alexgordon> I fancy an indian
* alexgordon ^ just realized the above makes absolutely no sense to anybody outside britland
<elliottcable> alexgordon ⑊ what
<elliottcable> you want to bang an Indian chick?
<elliottcable> we're talking red dots, not feathers, yes?
<alexgordon> no, I would like to eat an indian "takeout"
<alexgordon> elliottcable: oh god...
<alexgordon> "red dots not feathers"
<alexgordon> elliottcable: can you say that again, but as an op, so I can quote it accurately on twitter?
<purr> <gqbrielle> what i'm getting from this is that Nuck tastes like bananas.
<elliottcable> wat
alexgordon is now known as alexandertgordon
alexandertgordon is now known as alexanderteagord
alexanderteagord is now known as alexandertea
<elliottcable> alexandertea ⑊ wat fuck is that
<alexandertea> elliottcable: countdown
<elliottcable> hi
<purr> elliottcable: hi!
alexandertea is now known as alexgordon
<elliottcable> BangWithFriends.
<elliottcable> laughing my ass off.
AP_ has joined #elliottcable
<AP_> Here I am.
<elliottcable> o7
<elliottcable> paste your code, bitch <3
<elliottcable> alexgordon ⑊ /nick alexteabagordon
<AP_> The main function is in a seperate cpp file from the rest of the code
<AP_> and I just compile the two together, and I dont know how relevant it is.
<AP_> Here's the main() if that's relevant https://gist.github.com/anonymous/31c7fa091b95a77a6ae2
alexgordon is now known as alexteabaggordon
<alexteabaggordon> elliottcable: better?
<alexteabaggordon> syntax highlighted https://gist.github.com/fileability/38bc56bfcc8192373ff2
<elliottcable> reading
<elliottcable> lol hi AP_
<purr> lol
<elliottcable> AP_ ⑊ alexteabaggordon is a very skilled C++ developer.
<elliottcable> If he says something that isn't about penises, listen.
<elliottcable> God, this instructor's code is atrocious.
<elliottcable> It's nearly as bad as alexteabaggordon's.
<elliottcable> lol AP_ your declarations are inside your function
<purr> lol
<elliottcable> move the `void doit() {` part *after* the declarations, first off
<elliottcable> wat actual fuck is this shit
<AP_> I haven't the slightest
<AP_> are you saying that
rckts has quit [Disconnected by services]
* elliottcable sighs
<elliottcable> This is bad.
<elliottcable> This instructor's instructions and shit are fucking incomprehensible.
<AP_> I know.
<AP_> What are you saying to move?
rckts has joined #elliottcable
<elliottcable> My best advice: You're struggling enough with the concepts as it is (which is to be expected, it's difficult); fuck this guy. Drop out, and learn it elsewhere. *Maybe* take the class again later, if you need the credit badly, after having learned it well.
<elliottcable> Or, put it another way: I'm an experienced programmer, and I have no idea what you're supposed to do here, or what your isntructor wants.
<elliottcable> I'm marginally sure he's slightly retarded.
<AP_> I suppose I can fail this one assignment.
<AP_> The rest have gone well so far.
<elliottcable> making the code work would be fairly easy; I just have no idea *what he wants*.
<AP_> As in formatting?
<elliottcable> no, as in, what code he wants where, and what he's expecting you to do to fix this broken code.
<elliottcable> how much have you already done, here?
<AP_> I've pretty much just coded the functions outside of doit() and their calls and prototypes
<elliottcable> does it compile?
<elliottcable> you aren't currently saving return-values from your functions to variables, inside doit()
<elliottcable> so on L111, your displayDeliveryCharge is getting passed 0.0 and 0.0
<AP_> it compiles
<AP_> what do i have to change to get my return values
<AP_> because that's what Im getting in my debugging
<AP_> are just 0.0
<AP_> Or how do I not make it pass 0.0?
<elliottcable> it's not passing *anything*, yet.
<elliottcable> if you just type “12.34” into your code, it isn't going to do anything.
<elliottcable> `12.34;` is a meaningless statement.
yorick has joined #elliottcable
yorick has joined #elliottcable
<elliottcable> it's discarding the value.
<AP_> I understand that.
<elliottcable> similarly, just writing a function-invocation (the shit with the parentheses after it) alone, isn't doing anything for you
<AP_> I just don't see what to change to get it to work.
<elliottcable> `fooBarBaz();` is *also* discarding the value; or rather, it's discarding the result.
<elliottcable> instead, you need to write `myValue = 12.34;`
<elliottcable> or, in your case, `fooResult = fooBarBaz();`
<elliottcable> those variables are getting set to zero at the top of the function, and you never replace the zero with the result of that function-invocation.
<AP_> double parcelWeight = 0.0; double deliveryCharge = 0.0;
<elliottcable> yes, that's fine *there*
<elliottcable> but you, later on in your code, need to change what parecelWeight stores, into something else.
<elliottcable> you never do that inside the doit() code.
<elliottcable> you: A) set parcelWeight to zero, B) invoke some functions, and C) print parcelWeight. So all it's going to print, is zero.
<AP_> Uh...okay.
<AP_> I see what is going wrong
<AP_> but
<elliottcable> do you understand what I just said? if not, what not?
<AP_> "need to change what parecelWeight stores, into something else."
<AP_> is "something else" another variable I need to declare in doit()?
<AP_> Thats where I'm lost.
<alexteabaggordon> ok I'm back
<alexteabaggordon> I'm a very skilled C++ programmer
<elliottcable> nope. I'm sorry if I'm being obtuse, here's the direct commentary:
<alexteabaggordon> so if I say something that's not about penises, you should listen
<elliottcable> you're discarding the return-value of the function, instead of storing it to the variable you made.
<alexteabaggordon> COCK
<elliottcable> `enterParcelWeight()` does nothing by itself
<alexteabaggordon> AP_: this code has too many comments in it, but I'm sure there's nothing you can do about that :P
<elliottcable> you need to *store the return-value to a variable*, namely, the variable you made
<elliottcable> so change it to something like:
<alexteabaggordon> also shaft
<elliottcable> `parcelWeight = enterParcelWeight()`
<AP_> In the function call?
<elliottcable> yes.
<elliottcable> inside doit's implementation.
<elliottcable> you'll need to do the same thing with the other function that returns a value, too.
<AP_> Okay. I changed line 80 to parcelWeight = enterParcelWeight();
<AP_> and it returned the desired value
<alexteabaggordon> you need to set deliveryCharge too
<alexteabaggordon> in line 95, calculateDeliveryCharge(parcelWeight);
<AP_> to deliveryCharge = calculateDeliveryCharge(parcelWeight);?
<alexteabaggordon> presumably
<alexteabaggordon> AP_: and you should change displayDeliveryCharge() to return void instead of double
<alexteabaggordon> since it always returns 0.0
<AP_> I changed line 95 but I got an error.
<alexteabaggordon> what was it
<AP_> Nevermind, user error
<alexteabaggordon> it's kind of weird having function prototypes inside a function
<alexteabaggordon> line 50-52
<alexteabaggordon> but I dunno if you're allowed to move those
<AP_> deliveryCharge is being returned as an int in debugging
<AP_> No, I dont think I can
<AP_> I would like it to return as a double though.
<alexteabaggordon> AP_: debugging? as in gdb?
<AP_> When I compile it and run it.
<alexteabaggordon> AP_: how are you debugging it?
<AP_> If I enter 7.5 for the weight I should return 18.XX but I only get 18.
<AP_> visual studio
<alexteabaggordon> oh right
<alexteabaggordon> windows, obviously :P
<AP_> exactly
<AP_> So thats my last issue
<alexteabaggordon> isn't it supposed to print the answer out at the end?
<AP_> yes
<alexteabaggordon> and it prints 18 instead of 18.something ?
<AP_> Yes
<alexteabaggordon> AP_: oh well you're doing setprecision(2)
<alexteabaggordon> so that's why
<AP_> Should It be 4 then?
<alexteabaggordon> possibly!
<AP_> That worked
<alexteabaggordon> I dunno I normally use printf() instead so I'm not versed in all of this
<AP_> They say jump, and I say how high
<AP_> thats how these assignments go
<elliottcable> lol
<purr> lol
<elliottcable> got it working?
<elliottcable> alexteabaggordon, meet my girlfriend's brother.
<elliottcable> other alex, meet my C++-alex.
<AP_> bonjernno
<alexteabaggordon> well the good news is that elliottcable can no longer make fun of me for using too much whitespace!
<AP_> Oh I have one last thing
<alexteabaggordon> elliottcable: remember this? https://github.com/fileability/paws.normal.c/blob/master/paws.cc
<elliottcable> ... a bit
<elliottcable> no. no I don't.
<AP_> when I loop the program, I don't want the printheading() to run agian
<alexteabaggordon> elliottcable: it's from when you put a $1000 bounty on a paws impl
<AP_> In the do-while how can I have it ignore a function on the rpeat?
<AP_> *repeat?
<alexteabaggordon> I don't see a do while?
<AP_> main() is in a serpate cpp for whatever reason.
<alexteabaggordon> AP_: move the printHeadings() call out of the doit() and above the do {
<AP_> Do I have any alternatives? He says not to touch the main function.
<AP_> Youre saying move it from L66 to L47 in the main cpp?
<AP_> *the cpp with main()
<alexteabaggordon> AP_: you can pass a boolean to doit()
<alexteabaggordon> indicating whether the loop has looped
<alexteabaggordon> but that would be more code
<alexteabaggordon> it's easier just to… do the call to printHeadings() outside of the loop
<alexteabaggordon> that's the most obvious thing anyway
<AP_> I can't seem to get that.
<AP_> Oh well, I'm out of time anyway
<AP_> Thank you alex and elliot for you time.
<elliottcable> o7
<vil> hi guys
<elliottcable> o7 vil
<vil> elliottcable: how's things?
<elliottcable> good.
<purr> <gqbrielle> anything that makes elliottcable mad is funny.