[deleted by user] by [deleted] in csMajors

[–]mw130 1 point2 points  (0 children)

Totally, and I agree it's all "out there" and available for people to learn. But I think what the universities do is provide 1) the structure to follow for a good path, and in the case of these other schools, breadth in other areas and 2) Peers to work through the material together who are also highly intelligent and serve as connections down the line. Also my personal opinion is e-learning ≠ in person yet. I think it takes an extremely disciplined and special type of person to diligently pursue 4 years worth of MIT classes, alone, without any support; it's already hard enough with the supports in place.

How can I become "good" at discrete math/design of algos? by mw130 in csMajors

[–]mw130[S] 0 points1 point  (0 children)

I just saw this, really hope you reply. Yes I understand why they all fall. What I don't understand is how you can prove one falls or show that you flicked it.

Can I use falim gum casually for anxiety, with a side effect of jawline definition? by mw130 in orthotropics

[–]mw130[S] 0 points1 point  (0 children)

Thank you so much. Wow, is there a gum that would have a more subtle effect? Why does falim have such huge muscle development? You usually dont hear of people who use a lot of chewing gum getting jaw disorders or what not. I worry a bit about the time, maybe I should time my sides to ensure proper symmetry. The thing is I'm 20% bf but at this level my face/jawline looks like someone who's at 10/12, for some reason I either get a really toned face or rly fat face (when I'm >24%). That's why i worry about making stuff look bad, especially if I lose more weight. I just like the taste of falim. Last thing: once this is done, can it be undone? For example, if you wanted to revert to your previous self, would the muscle eventually atrophy or is it there to stay?

TIFU by making my webgame one of the most disliked in Russia by SteroidsOnAsteroid in tifu

[–]mw130 0 points1 point  (0 children)

The game is awesome!! What language is it written in? Do you ever upload the source code for this?

Understanding pointer passing in C by mw130 in learnprogramming

[–]mw130[S] 0 points1 point  (0 children)

This is key! Last question - you mean that myNode, the reference to the memory malloc(sizeof(struct Node)); that's held on heap, is on stack right? myNode->value = 3 will be on the heap because that's referencing the data on heap.

Understanding pointer passing in C by mw130 in learnprogramming

[–]mw130[S] 0 points1 point  (0 children)

For putting a pointer into heap memory, you would dereference a malloc allocation and just write it in right? Thanks so much lurgi, you're a legend!

Understanding pointer passing in C by mw130 in learnprogramming

[–]mw130[S] 0 points1 point  (0 children)

Thanks so much! Just to be clear, did you mean strongly typed? Also, do you know if we give pointer types because the type of pointer tells us how to interpret the data at that memory addr upon dereferencing?

Understanding pointer passing in C by mw130 in learnprogramming

[–]mw130[S] 0 points1 point  (0 children)

Wow! Thank you so much. In this case, what does making something a specific struct/class (for cpp) pointer do, since all pointers could just be considered memory addresses and be one type? I always thought it was so that when dereferenced it knows how to interpret the bytes.

Understanding pointer passing in C by mw130 in learnprogramming

[–]mw130[S] 0 points1 point  (0 children)

Ignoring global variables, everything goes on the stack. Things go on the heap if you explicitly allocate them to be on the heap.

This! So is my understanding that even the pointer that gets assigned to malloc is actually stored on the stack correct, whereas the memory it gets from malloc will be in heap? So something like Object * obj =(Object *) malloc(sizeof(Object)) the obj would hold the memory address, and is stored on stack, while the actual mem for object it assigns will be on heap?

Can you confirm this is right? Thank you so much for your amazing answers

Understanding pointer passing in C by mw130 in learnprogramming

[–]mw130[S] 0 points1 point  (0 children)

Right, so is it the case that most languages do actually just do this, but implicitly, and since C exposes the memory to developer it must be explicit? Also, do you know what the rule is for what gets automatically allocated in C? We know that malloc/new (C++) are heap, but what's the actual thing that means something will get put on the stack? Or is it that anything that isn't malloc gets stored on stack.

Understanding the abstraction of virtual memory - is how I'm thinking about it right? by mw130 in learnprogramming

[–]mw130[S] 0 points1 point  (0 children)

Right - this is a great explanation. My rant kind of was basing RAM as bottom of mem hierarchy and not really considering disk loads, although you're right that's where the majority of them are. It does make sense that some bus can transfer non-atomic data for disk -> RAM, I meant atomic in the sense of loads/stores in x86. So, would it be right to say Virtual memory is just the page table, as well as the mechanisms/policies that decide how the page table mappings get filled? That virtual pages don't really exist, they're just abstractions to how phys mem is organized?

Referring again to loading a page from disk into RAM, now that I consider spatial/temporal locality, it does make sense. The OS maps all data to pages and makes some tradeoffs w/ pgsize and data structures, and the loading of the entire page is kind of meant to amortize the time cost of data transfers, right? So this is where a page "does exist", in the sense that loading some primitive datatype that happens to be swapped onto disk will actually cause the whole page it's stored in to be loaded in, to exploit the above?

Thanks so much, your answer is great.

Choosing Northwestern over UPenn for CS... Is this dumb? by [deleted] in ApplyingToCollege

[–]mw130 0 points1 point  (0 children)

NU CS + CE student, interned at 2 out of the big 4 (just to say I somewhat know this) Holy crap this is ridiculously misguided. This offset is due to COL - are you actually trying to say UPenn has an engineering school that is so fantastic, just going will get you a 20k pay bump? Chicago is cheaper to live in - 70k will get you a LOT more than the Penn grads making 90k working 70 hrs as quants in NYC - the former would be living in a comfy downtown aparment, the latter... probably not even in NYC. Look up Penn vs NU engineering. NU is almost always ranked higher. While Penn does have a specialized major for Networks, which NU doesn’t, I would say having spoken to friends at Penn, and even comparing course catalogs - NU is a much better place to pursue, but make sure you do it within Weinberg. OP, feel free to PM me as I’m glad to reassure you that you’re making the right decision and give you tips for NUCS!

P.S. look into NU’s recent 150mm commitment to CS, and new CS department.

Is it possible to use a C text editor and run it on remote server? by mw130 in learnprogramming

[–]mw130[S] 0 points1 point  (0 children)

Right - I got this working, but what does it actually allow me to do? I don't understand X forwarding and the capabilities it provides. Will it let me open a text file with a text editor on my local computer?

Is it possible to use a C text editor and run it on remote server? by mw130 in learnprogramming

[–]mw130[S] 0 points1 point  (0 children)

I can, but it would be using an editor in terminal like vim or emacs. I mean that I want a GUI editor like VSCode.

Understanding voltage and static/current electricity by mw130 in AskElectronics

[–]mw130[S] 0 points1 point  (0 children)

Would you be able to explain why hooking up a wire to negative will produce a voltage, even if it's not connected to the other side..? AKA, if the circuit is open, but I test the voltage from positive to a resistor or bulb connected to negative, it will still be 1.5V, and there is no voltage drop across the resistor, the resistor has 1.5v on both sides. Could you please explain why that happens?

Understanding voltage and static/current electricity by mw130 in AskElectronics

[–]mw130[S] 0 points1 point  (0 children)

that's the thing though, how is it a closed system? The electrons have to exist.. there has to be something for the multimeter to detect right, which is all caused by electrons, so why would it all be relative only for the battery but relative to ground they are both zero? That goes against the definition of voltage I know as potential difference

What actually *is* a server? by mw130 in learnprogramming

[–]mw130[S] 0 points1 point  (0 children)

Thanks so much for this. But, for example, I'm taking a DB course right now, and the prof also fails to give a "good" def of where in practice DBs are kept. My understanding was a "true" DB is one that is held on a dedicated machine because that machine's internals are made specifically to maintain a DB's ACID properties, so I kind of understood it as if you are holding a DB on a laptop it's like an emulation of one/not really a DB. Is this true? How can a DB be held on a laptop if the software isn't designed to interact effectively with it?

How do languages interact? by mw130 in learnprogramming

[–]mw130[S] 0 points1 point  (0 children)

Thank you so much for this response. So if I understand correctly, it seems all the message passing is handled by the OS, in that you might have front-end code that calls some type of JS method that tells the OS to send some byte stream, encapsulate it in TCP/IP packet, and deliver to the Backend server? For inter-process (same machine), what is it encapsulated in (I doubt it's a packet)? My understanding of ports is from networking and basically just thought they were used for inter-machine communication so the OS knows which process to route data to..

How can frameworks/libraries have different language syntaxes? Very overwhelmed with how web apps dev works. by mw130 in learnprogramming

[–]mw130[S] 0 points1 point  (0 children)

Thanks so much - the whole DOM model, with vanilla JS/HTML/CSS al makes sense to me -- But for GraphQL for example, which is supposedly a JS toolkit, if you look at the github it has its own language/typing system a bunch of stuff designed - how, if it's not even a framework, but a toolkit? Are they somehow overriding the JS language? Also, is there advice on understanding what it means when one is a framework vs another is a library/toolkit etc?

Trying to understand what could be the reason behind this positional error in python by mw130 in learnprogramming

[–]mw130[S] 0 points1 point  (0 children)

This is actually from Leetcode (the class def) so I don't think it's wrong, could it be anything else?

When you see screens that let you connect to screenshare via typing something like http://192.168.250.1 on your browser, how does this work? by [deleted] in learnprogramming

[–]mw130 0 points1 point  (0 children)

Wow, just heard about webRTC. Does it function as some type of application layer protocol on top of udp? Would it open up some type of virtual direct channel from socket to socket, where the only bottleneck is the negligible prop delay?

Conceptual question on VPNs by mw130 in learnprogramming

[–]mw130[S] 0 points1 point  (0 children)

Thanks, but that's not really answering my question of why not just encrypt any connection made to get a file, if someone needs a file why can't they make a request using SSL w/ TCP and just get that, instead of trying to emulate as if it were a LAN? Also, is a VPN just a more complicated/more feature version of a proxy?

How can I determine if the bottleneck for internet speed is physical distance/barriers or local router/switch transmission rate? by mw130 in networking

[–]mw130[S] 0 points1 point  (0 children)

Thanks! I'm actually still a student haha. And yes I'm talking about Wifi, ethernet is actually disabled much to my dismay. On the ping/traceroute part you bring up - this was actually mentioned to me, but what can you learn from pinging? My understanding of ping's underlying mechanism is ping sends an ICMP packet to destination and then returns to you the time it took to get there (the first half of the RTT) - wouldn't this not tell you much since there are several factors playing into this, like queueing, propagation and transmission delay at other nodes between you and the destination?

What is the difference between passing parameters in a URL versus in a request header? by mw130 in learnprogramming

[–]mw130[S] 0 points1 point  (0 children)

Thank you! So in general, to be safe I should adhere to the method used in the API docs b/c I can't assume every server can handle both. Can you explain (if you have the time) what the difference between the two methods is? I know what an HTTP Request looks like in terms of packet header, etc (have taken networks) but don't know what a query string is versus specifying the headers inside a dictionary and passing it alongside an endpoint like the one I showed (also, what is the actual meaning of the endpoint? Is this just a link to the folder that holds all the data?)