• Breaking News

    Thursday, March 18, 2021

    How would you explain what 'Object Oriented Programming' is to a kid? learn programming

    learn programming

    How would you explain what 'Object Oriented Programming' is to a kid? learn programming


    How would you explain what 'Object Oriented Programming' is to a kid?

    Posted: 17 Mar 2021 04:28 AM PDT

    Give your simplest definition.

    submitted by /u/Sxencode
    [link] [comments]

    Algorithms are just abstract math?

    Posted: 17 Mar 2021 11:24 PM PDT

    I am learning "algorithmic toolbox" course on coursera, week 3, and still I don't get anything. I mean, are algorithms just all abstract math? Because right now it is. Logarithms, polynomials, reccurence and god knows what. I am not too good at math, and I was wondering if I ever would be able to solve algorithmic problems and get a job at faang (that's one of the main reasons I started this course)? Or should I start another course on math or calculus (I am afraid it's going to be a rabbit hole, because there will be always something to learn)? Please help

    submitted by /u/whoeverdontmatter
    [link] [comments]

    My first few days on the job as a developer were horrible - Please don't make the same mistakes as me

    Posted: 17 Mar 2021 09:07 AM PDT

    So in the middle of University I eventually found an internship as a software developer for a small company that worked mostly on embedded software. I had been learning programming for a while and felt fairly good about my abilities at that point in time. Then on the first few days on that first job as a developer I hit a wall, and I hit it really hard. But here's the thing, that wall was mostly my own doing and could have been avoided easily by applying a few simple ideas. So here's a video I shot going over a couple ideas I wish I followed when first starting out that would have made things a lot easier. I know many of you here have the end goal of making programming into a career so I thought it would be useful to some of you!

    (Obviously not everyone wants to sit through a YouTube video so the tips are also in text format down below.)

    3 Tips I wish I followed on my first developer job(Youtube link)

    1. Adjust your expectations. That goes for the expectations you have for yourself and what your skill level is, but also for what you perceive as the expectations other members of your team have for you. Programming is one of those things where the more you learn, the more you realize how little you know. Often you'll fall into a trap as a beginner to think the end goal is to have complete and perfect knowledge of a subject, and that failing to achieve that is a problem. I can't emphasize enough how that's not the case at all. You'll obviously always strive as a developer and programmer to learn as much as possible about whatever subject, technology or stack you use the most, but you also need to have realistic expectations that there will always be things you don't know about and you have to learn. That's not an issue at all, all your past experience and abilities will make it easier and easier over time to learn new topics or concepts, but situations where you're faced with a brand new problem will remain fairly constant throughout your career. I like to think of it that way, your job as a developer or software engineer is mostly about being able to tackle new problems, figure out things that you've never done before or things that have never been done before at all. It's about using your current knowledge as small puzzle pieces that you can put together into something new or different. As a beginner you just have fewer puzzle pieces to work with, so don't beat yourself up over not knowing something already, your job is to figure things out with what you have, or to fill in the gaps with new knowledge to make things happen. Your colleagues will have gone and are still going through the same process so they won't expect you to know everything either.
    2. Ask questions. I know that sounds stupid but it kind of goes along with that first point I made. If you feel like you're not adequate for the job you're tasked with or that you should know something already you might be scared of asking questions to your colleagues. On my first internship, I came out of my first meeting with a task I understood basically nothing of. I should have asked questions to understand it better but since it was given to me I assumed that I should know how to do it. Here's the thing though, like I said earlier, almost no one has complete and absolute knowledge of even their little corner of the programming world, everyone has knowledge of a bunch of different elements sporadically placed within that corner. What happens because of that is that your colleagues or whoever is mentoring you on your first job won't really have any way of knowing where your understanding begins and where it ends on any particular subject. They also have plenty of work to do so they're probably not going to go out of their ways to explain every little detail you might need so you understand what you need to understand, but when you ask, they'll be happy to help. So when you see you have gaps in knowledge, whether it's a concept, an acronym that was used in a meeting, an internal tool, whatever it is, ask questions so people around you know what the gaps are in your understanding and can help you address them. Make sure to take plenty of notes so you don't have to ask the same questions over and over again, and try first to figure things out on your own before automatically going to others for help. But when you're truly lost, and you will be at times, make sure to ask questions. In many cases a couple minutes with a colleague will get you up to speed on something faster than if you spend an hour or more figuring it out by yourself, and it's in everyone's interest to get you up to speed as fast as possible so you can contribute to your full potential. ***Just be respectful and don't take it personal if people can't help you or answer your questions right away, other developers and seniors have a lot of work to do too, so they might not always be available. That being said, almost all developers I've worked with try their absolute best to help out other people, especially newer members on their teams. ***
    3. Be proactive with your time. Your first days/weeks as an intern or as a junior are most likely going to be really slow. You might have a few simple tasks given to you fairly early on but even then, they will probably trickle in at a pretty slow pace to get you used to whatever project you're working on and the way the company you are at operates. With a bit of luck that means the tasks you end up with won't even fill out the entirety of your work time for a little while. Make sure to use all that extra time you have effectively. That means, play around with the codebase you're working on in a meaningful way. Don't just sit around and mindlessly read lines and lines of code, instead maybe try to implement a bogus feature on a throwaway branch. That way you'll build some stress free, low stakes, experience with the project you're working on. Maybe you could even ask to shadow another developer for a little bit of time to see what they're working on, what they're taking in consideration while implementing features or fixing bugs, or maybe what tools they're using. Maybe you can ask a senior to run you through the next code review he does, so you can learn what he looks out for when doing them. There's honestly plenty of opportunities to learn and get up to speed with your team and the project you're working on. Try to figure out some ways that work for you and that your team is comfortable helping you with. Just make sure you don't let all that time you have on your hands as a junior or an intern go to waste because that's when you'll have the biggest opportunity for very rapid growth. It'll also ultimately make a good impression on the team since it will show you're trying to get up to speed and learn as much as you can. Be creative, be proactive, and you'll catch a lot more quickly.

    Anyway I hope this ends up being useful to some of you. It probably sounds obvious to many people but sometimes just being actively reminded of something seems to make it easier to put it into action when you run into that situation. I wish I put those ideas in action right from the start of my career so hopefully I can help others do it instead! Also, English isn't my first language so my apologies for any grammar mistakes in this post!

    submitted by /u/TheGreenDeveloper
    [link] [comments]

    How to check if every element array meets condition before returning statement? [Javascript]

    Posted: 17 Mar 2021 07:39 PM PDT

     const gameboard = []; gameboard.push([3, 0, 6, 5, 0, 8, 4, 0, 0]); for (var i = 0; i < gameboard.length; i++) { for (var j = 0; j < gameboard.length; j++) { if (gameboard[0][i] === 0) while (gameboard[0][i] < 9) { gameboard[0][i]++; let isArrayValid = true; if (gameboard[0][i] !== gameboard[0][j]) { isArrayValid = false; break; } } 

    Okay, so what I'm doing here is comparing every 0 in the array to every number in the array to make it so that it goes from 1 to 9 until it hits a number that's not equal to it in the array. Essentially I want every number to be different.

    However it doesn't scan the entire array, it just stops checking once it finds one number that meets the condition. This is obviously terrible because there can be a number that is equal but is later in the array.

    for example, 1 is not equal to 3 so it stops at 3. So now all my zeroes are now equal to 1. How do I make it so that it scans EVERY number in the array before stopping at a number that it isn't equal to?

    Also when the condition is called again because there is more than one 0, it picks up where it left off rather than starting from the beginning which results in all the 0's being 1 because it doesn't know that there was already a previous 0 changed to 1 in the array.

    My array should really be equal to [3,1,6,5,2,8,4,7,9]

    but instead I'm getting, [3,1,6,5,1,8,4,1,1]

    submitted by /u/someguyhere0
    [link] [comments]

    Good websites to develop skills and/or learn new languages and technologies?

    Posted: 17 Mar 2021 08:30 PM PDT

    I was looking to use this summer to self teach many of the following languages/technologies

    • C++
    • Java
    • JavaScript
    • HTML/CSS
    • SQL
    • Python
    • React
    submitted by /u/lankysmart
    [link] [comments]

    All the tutorials I can find are teaching syntax not programming, need help

    Posted: 17 Mar 2021 04:35 AM PDT

    I am new to programming. My problem is that whether it's youtube, udemy or whatever, every "x language tutorial" is teaching syntax in that specific language, not programming logic, which is what I, as a beginner, need.

    Is there any proven course to work for learning programming logic / algorithms? I am not interested in learning how to declare a variable, how to create an object, or what types of loops there are in x language, I want to learn the logic.

    I need a course to help me solve real problems, to help me when dealing with the real world. Youtube is only helping me parrot syntax of x coding language, that I don't know what to do with when faced with a problem.

    submitted by /u/mmorpgquest19
    [link] [comments]

    Do a lot of people give up when learning how to code?

    Posted: 17 Mar 2021 07:56 PM PDT

    Basically the title. I find it weird how there is a 'demand' for cs people if it is so popular.

    submitted by /u/Furious_Walker
    [link] [comments]

    Should I take a programming class?

    Posted: 17 Mar 2021 09:11 PM PDT

    I can take programming as an elective next year in high school. Would I learn better by teaching myself or taking a class? I would like it to be as stress free as possible but that depends on the teacher, though I don't want to procrastinate in learning.

    submitted by /u/Zach-150
    [link] [comments]

    User-define Function Not working in Header + Source File.

    Posted: 17 Mar 2021 08:29 PM PDT

    Sorry for the novice question, but I am fairly new to C++, and I am implementing a function to print out a vector, very similarly to the format of printing Python lists. My code is as below:

    #include <iostream> #include <vector> template <class T> void print_vector(std::vector<T>& x); int main() { std::vector<int> foo{42, 0, 9}; print_vector(foo); } template <class T> void print_vector(std::vector<T>& x) { std::cout << '['; for (int i = 0; i < x.size(); i++) { std::cout << x[i]; if (i == x.size() - 1) std::cout << ']' << std::endl; else std::cout << ", "; } } 

    This works pretty much exactly how I wanted it to. I decided to declare this function into a header file called function.hpp and define it in function.cpp, and include it in main.cpp

    Function.hpp:

    #ifndef FUNCTION_HPP #define FUNCTION_HPP #include <iostream> #include <vector> template <class T> void print_vector(std::vector<T>& x); 
    

    No comments:

    Post a Comment