• Breaking News

    Thursday, January 14, 2021

    This xkcd comic speaks on how some things are deceptively hard to program. What are some other examples of this? learn programming

    This xkcd comic speaks on how some things are deceptively hard to program. What are some other examples of this? learn programming


    This xkcd comic speaks on how some things are deceptively hard to program. What are some other examples of this?

    Posted: 14 Jan 2021 04:06 PM PST

    https://xkcd.com/1425/

    Adding text to avoid removal from automod.

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

    [Blog Post] How to distribute Python programs as stand-alone executables (How to use PyInstaller)

    Posted: 14 Jan 2021 04:12 AM PST

    As many python Developers know, python is (usually) written and distributed as source code that others must compile before using and sometimes download additional libraries. This may stop you from creating a software to distribute (and maybe sell) to users who are not familiar with the language.

    I wrote this short article about how to compile your Python program and be able to distribute it to others more professionally!

    You will learn how to use PyInstaller to do so!

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

    Is it acceptable to copy code from, for example, stackoverflow to create specific features for your own personal projects even if you didnt necessarily come up with that code by yourself, especially when creating a portfolio for jobs? [full details in text]

    Posted: 14 Jan 2021 03:24 AM PST

    Hey r/learnprogramming,

    Just a question in regards to acceptable/ethical approaches in creating your own projects for employers to see when applying for jobs (for my purpose, front end development)

    Lets say you have the big picture on what you'd like to create and you're making great progress but there is a section or two that you dont know how to code.

    lets say theres a solution on, for example, stackoverflow that gives you the correct solution that you are looking for. is it acceptable/ethical to just copy the code from x source and paste it into your project even though you 1. dont fully understand the code (of course id try my best to understand why they did that) and 2. might not have come up with that particular solution all by yourself?

    Is this something that is acceptable when creating your own personal projects even though there are parts of your project with code that you did not come up with by yourself? Can you pass the project as something that you created even when applying to jobs?

    Just wondering if this was something that is frowned upon or if its something that all programmers do (i hear people who just copy and paste code from stackoverflow for their fulltime job and that programmers always looks up things they dont know). but just wondering for my purpose of constructing my own portfolio for applying to entry level jobs, is this 'ethical'?

    I noticed that for certain parts of my projects, i know what i need to do, i just dont know how to code that feature by myself. so I look it up, find the solution i am looking for, and then copy it into my project.

    I hope my question makes sense, thanks to anyone for any advice i can get!

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

    Is Colt Steeles Advanced Web Dev Bootcamp worth it?

    Posted: 14 Jan 2021 02:15 PM PST

    I'm currently going through his updated Web Dev Bootcamp, and was thinking of following it up with the Advanced Bootcamp. But, it looks like there are topics in the Advanced Bootcamp that are covered in the updated version of the Web Dev Bootcamp (such as CSS Transforms/Transitions/Flexbox, AJAX, OOP etc). Has anyone taken both?

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

    Can you recommend a good introductory book on Computer Science in general? I mean the stuff you have to know *before* even starting to learn programming. Like terminology, what the field contains, history/overview of CS and types of careers, what is programming, just the broad basics?

    Posted: 14 Jan 2021 08:00 PM PST

    Ultra beginner here-- Even the FAQ stuff is more advanced than what I'm looking for. I'm quitting my job as a mechanic, making a career change. Tired of busting my ass for mediocre wages. Also taking a year or 2 off. I will have ample time to delve into programming. But I need a good overall intro book for CS and/or programming, so I can imagine the big picture before deciding on where to focus my efforts. For example, think back to your "intro to CS" class in college or high school, what books or resources do you recommend? Thanks in advance.

    submitted by /u/SR-71
    [link] [comments]

    [Java] code keeps magically returning false on using hash maps to find patterns in two strings

    Posted: 14 Jan 2021 11:03 PM PST

    LC Easy problem: https://leetcode.com/problems/word-pattern/

    My code (with comments):

    class Solution { public boolean wordPattern(String pattern, String s) { //breaking up s into a words list StringBuilder fragment = new StringBuilder(); ArrayList<String> tracker = new ArrayList<>(); for(int i = 0; i < s.length(); i++){ if(s.charAt(i) == ' '){ tracker.add(fragment.toString()); fragment = new StringBuilder(); } else if(s.charAt(i) != ' '){ fragment.append(s.charAt(i)); } } //add the leftover string fragment into the list tracker.add(fragment.toString()); //size check if(pattern.length() != tracker.size()){return false;} //make a hashmap Map<Character, String> map = new HashMap<>(); for(int i = 0; i < pattern.length(); i++){ char a = pattern.charAt(i); String b = tracker.get(i); //logic check to see if mappings are unique to each other if(map.containsKey(a)){ if(map.get(a) != b){return false;} } else{ if(map.containsValue(b)) return false; map.put(a, b); } } return true; } } 

    Failed test case:

     Your input "abba" "dog cat cat dog" Output false Expected true 

    No clue why it keeps coming out "false". I've been tracing my code and it should be working just fine and giving me "TRUE". I even printed out my hash map and its (a : dog, b : cat) which is also correct.

    Very frustrated with this one, would love help.

    Edit: Looking at the LC discussion tab and found this answer with my exact same logic:

    public class Solution { public boolean wordPattern(String pattern, String str) { String[] arr= str.split(" "); HashMap<Character, String> map = new HashMap<Character, String>(); if(arr.length!= pattern.length()) return false; for(int i=0; i<arr.length; i++){ char c = pattern.charAt(i); if(map.containsKey(c)){ if(!map.get(c).equals(arr[i])) return false; }else{ if(map.containsValue(arr[i])) return false; map.put(c, arr[i]); } } return true; } } 

    So I'm suspecting typos or some kind of compiler error. Still clueless.

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

    Completely overwhelmed coding by day but love the challenge at night...

    Posted: 14 Jan 2021 08:11 PM PST

    Not sure why, but I find learning incredibly overwhelming during the day. So much so that half the times I sit down to code it ends in frustration and even some anxiety. At night, after 8pm or so I've eaten, had a beer, am slightly tired and for some reason I find everything fairly interesting. I could care less about how complex a concept is, I just get into a 'tinkering' mode and play around with the code I'm having trouble with until I figure out what's going on.

    I've been learning Kotlin for the last few months and things are getting a tiny bit harder now and I'm noticing my anxiety gets the better of me during the day. Everything starts looking like Chinese and more complex than it actually is. At night... I don't have any of these feelings.

    Just wondering if others have felt this way and if so.. how can you possibly progress career wise if you can only do this sort of metal work at night ?

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

    git fetch

    Posted: 14 Jan 2021 07:40 PM PST

    I know that git pull basically fetches the changes from the remote repo and merges the remote changes to you local repo

    From what I understand, git fetch just gets the changes but doesn't do anything else. So what happens to the changes that fetch got if they aren't merge? Are they sitting somewhere? Would it prompt you if you want to merge? I don't really get this command.

    submitted by /u/2kfan
    [link] [comments]

    I’ve been a front-end web designer for 15-years and I’m looking for new challenges. Suggestions?

    Posted: 14 Jan 2021 08:53 PM PST

    I've been a front-end web designer for 15-years and I no longer find it challenging. Maybe it's covid, but I'm just bored and looking for a change of jobs and skills. I've built hundreds of sites using HTML/CSS, jQuery, and some basic JS. Most of my sites for the past few years have been low-level PHP or ColdFusion for dynamic includes of shared content across pages (but nothing beyond that). I want to move into a more challenging role that still allows a lot of creativity. There are so many languages I'm not sure what would be the most logical to start with. I originally thought about JavaScript development, but there are a million frameworks and I'm confused what they're all used for. Node? React? Vue?

    Looking for suggestions, but also looking for others that have made the transition from front-end designer to programmer/developer. Maybe I don't do JavaScript at all? What do you do?

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

    Accessing Cpanel with IP address

    Posted: 14 Jan 2021 06:17 PM PST

    Just landed one of my first proper clients and having trouble accessing the CPanel of there existing website.

    The previous developer has shared the login details for the Cpanel, although I cannot reach the login page.

    Website: http://nourishyouyoga.com.au/

    IP Adress is: 94.73.147.14

    Things I have tried:

    1. http://nourishyouyoga.com.au/cpanel
    2. http://94.73.147.14 :2083

    The client also provided the following url ftp.nourishyouyoga.com.au but still there is no where to login.

    Sorry if this is a noob question, any help will be extremely appreciated. Thank you!

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

    What are some good free resources to learn back end development

    Posted: 14 Jan 2021 08:03 PM PST

    Hi, I do front end development mostly but I want to master backend development now. What are some good free resources to learn back end development? I was only able to find resources on front end dev online. But I want to learn more about back end dev- like best practices to code your APIs, some basic level of system design, etc. Also I'm trying to decide which framework will be more in demand in terms of future job prospect- ASP .NET core or Java Spring Boot? Thank you in advance!

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

    Are HTTP verbs like PUT,PATCH,DELETE etc only useful with REST APIs?

    Posted: 14 Jan 2021 11:27 PM PST

    I have only ever seen usage of the above HTTP verbs with REST APIs when we want to update one/many instances of a resource or delete them. In normal web apps, I have only seen GET requests to get content, and POST requests when submitting forms.

    So are all verbs other than GET and POST only useful in REST APIs? Since HTTP predates REST, were the other verbs defined along with GET and POST or did they come into occurence later when REST was defined?

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

    Nursing to Programming...a life transition - to boot camp or not to boot camp

    Posted: 14 Jan 2021 12:33 PM PST

    Hello all, I am teaching myself python at this time and using a few "tutorials" online that I found from various sources starting with "Automate the boring stuff with python". I selected python as my start because well, I wasn't sure where to start (thanks FAQ) and now that I have started something I feel good about this transition.

    I am wanting to make this transition as best as possible for myself and my family (with a baby on the way). Would it be most beneficial for me to do a boot camp to help expediate my learning and hopefully get a job sooner than later or would I be better off trying to get into a college program to learn?

    Thanks guys for opinions and resources to help further me in my transition.

    submitted by /u/Icy-Scratch5289
    [link] [comments]

    Need help getting JGrasp working for Java

    Posted: 14 Jan 2021 09:53 PM PST

    This is a problem with the JGrasp software, not my coding itself.

    My code (which I copied from a video to make sure I had code that would actually work):

    public class Tester

    {

    public statis voic main(String[] args)

    {

    System.out.println("My name is SMGB_NeonYoshi");

    }

    }

    The output:

    ----jGRASP exec: javac -g Test.java

    ----jGRASP wedge error: command "javac" not found.

    ---- This command must be in the current Working directory

    ---- or on the current PATH to use this function.

    ---- working directory is "C:\Users\gideo\Desktop\Database Integration".

    ---- PATH is ";C:\Program Files\Java\jre1.8.0_271\bin;C:\Program Files (x86)\Common Files\Oracle\Java\javapath;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Windows\System32\OpenSSH\;C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common;C:\Program Files\NVIDIA Corporation\NVIDIA NvDLISR;C:\Program Files (x86)\Gpg4win\..\GnuPG\bin;C:\Program Files\Microsoft SQL Server\130\Tools\Binn\;C:\Program Files\Microsoft SQL Server\Client SDK\ODBC\170\Tools\Binn\;C:\Program Files\dotnet\;C:\Users\gideo\AppData\Local\Microsoft\WindowsApps;C:\Users\gideo\.dotnet\tools".

    ----

    ---- Make sure you have the full JDK, not just the JRE, installed.

    ---- The JDK is available from https://www.oracle.com/technetwork/java/index.html.

    ----jGRASP: operation complete.

    I'm missing something that is needed to get any Java command to work, but I don't know where to get it (the link it gave isn't helpful) or what to do when I get it.

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

    Visual Studio Heap vs executable heap

    Posted: 14 Jan 2021 09:49 PM PST

    How does the way the heap is treated in Microsoft visual studio differ from the way windows 10 treats the heap? I'm trying to work on Xenia (the XBox 360 emulator) right now, but I get exceptions (invalid memory accesses) while running in visual studio (same in debug and release mode) that I don't get while running the executable in the release folder. This is strange to me because I heard that the debug heap is managed differently than the release version heap, but I'm curious how the way the heap is managed changes between the release running in VS and the executable from the release folder. I tried running an iso (Bioshock infinite) from the release version when run from VS, and it gave me an exception, but I don't get that exception (or at least it doesn't crash) when simply running the executable from the release folder. I'm confused on why this is and any clarification would be awesome.

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

    Well this is interesting (google foobar)

    Posted: 14 Jan 2021 09:39 PM PST

    I've been teaching myself python for a little over a year on the side just cause I think programming is BA, doing simple things like making tkinter/pyqt GUIs that interact with databases.

    I'm working on a little side project that scrapes various websites for nhl prospect's game logs (eventually want to try making a flask site with some data science stuff based on the scraped data) and BAM, I get this weird pop-up thing and it turns out it's the google foobar challenge.

    I got through the first level in a couple hours, but am worried the next couple will make me feel stupid haha. I'm definitely going to at least try, it's for sure going to be challenging and should be a good learning experience.

    Like 90% of what I code I have to google to know what I'm doing, and have no background in programming besides what I've done in the past year.

    Anyone have any experience with the foobar challenge? I'm curious as to really what I'm getting myself into.

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

    If you know ReactJS, is a job in React Native hard to learn?

    Posted: 14 Jan 2021 09:06 AM PST

    I've heard it's easy to be able to learn React Native after you've learned ReactJS, what are some key differences?

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

    Javascript help! How to use a while loop to change class on an animation

    Posted: 14 Jan 2021 09:21 PM PST

    I have created an animation that moves after clicking the run icon, when it reaches the end of the screen, it will reset to the beginning and "levels up", becoming a different color by adding a classlist.

    I am able to level up once into gold after reaching the end of the screen, but now I'm stuck on the while loop part of it. I want the next level up to be pink, blue, etc, So I tried setting up a counter and while loop but can't seem to figure it out.

    Here is the program so far. -> http://jsfiddle.net/mept9g1u/

    (click the run text to animate)

    Any help would be amazing!

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

    Learning programming 8+ hours per day as a student. Is this going to be as mentally intense in the professional environment? Did I get I get I to the wrong career ?

    Posted: 14 Jan 2021 09:10 PM PST

    I am a CS student right now and been programming and learning all the material for 8 hours a day. At the end of 8 hours I'm pretty wasted and useless.

    In the professional environment, should I also expect this out of mental output or does it ease up a bit? I don't know if I can have a normal life if I keep up this pace because after 8 hours I am pretty much useless...

    submitted by /u/Educational-Spite-77
    [link] [comments]

    How to learn web development for my situation

    Posted: 14 Jan 2021 05:20 PM PST

    I was hoping to get some guidance for how I could approach learning web development for my situation. So I have minimal coding experience. I am a small business owner that is almost entirely a website based product. The majority of the website is allowing users to navigate to different pages that display data pulled from our database in tables and graph forms. There is also many filters that allow them to filter through the data to see what they want. We have all the data in a database through Sql. I currently have a website development team.

    However, once the website is completely developed, I would like to have enough coding knowledge to be able to update or create new pages on the website in an appealing way when needed. For my situation, here a few questions:

    1. How should I go about learning web development for this situation?
    2. What resources should I use?
    3. Where do I begin?
    4. Is this possible to learn in about a year if I dedicate anywhere from 4-8 hours a week learning?
    submitted by /u/joshk613
    [link] [comments]

    Course recommendations

    Posted: 14 Jan 2021 09:05 PM PST

    So i am planning to take some time off from work to try to learn programming mostly for software development and to make websites i still don't know if i will be able to pay courses in a university so i wanted to know if any of you knows a good courses online to learn on how to program on those specific subjects (doesn't matter if i have to pay) or if you live in North Carolina if you can recommend me for a 6 months course i would love to know (sorry for my english i am not a native speaker)

    submitted by /u/Inocent-Onion
    [link] [comments]

    Help with && Booleans

    Posted: 14 Jan 2021 08:54 PM PST

    Hello I'm doing the MOOC Java class one and I have been having an eternal trouble with the && operator. I can code around it using multiple if statements, but wanted so see why this code is wrong:

    System.out.print("Lower bound? ");

    int lowerBound = Integer.valueOf(scanner.nextLine());

    System.out.print("Upper bound? ");

    int upperBound = Integer.valueOf(scanner.nextLine());

    for (int index = 0; ((Integer.valueOf(list.get(index)) >= lowerBound) && (Integer.valueOf(list.get(index)) <= upperBound)); index++){

    answers.add(list.get(index));

    }

    System.out.println("Numbers: " + answers.size());

    The task is to input a file via path, which contains the numbers

    300

    9

    20

    15

    The lower bound is 15

    The upper bound is 20

    Right now I'm getting a result of zero. it should be 2. From what I can see the boolean is correct in but it's obviously not cause I keep getting 0. Unless it is a for loop error because the index grows outside of the list bounds. Or a third thing I'm not seeing cause I'm blind. Any and all help is greatly appreciated.

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

    Anyone looking for a beginner coder study buddies?

    Posted: 14 Jan 2021 08:38 PM PST

    Hello everyone! I'm 18 years old looking to get into programming, I'm looking for an accountability buddy where we can keep each other on track and help each other with any questions/ problems.

    Right now I'm learning on freecodecamp (learning HTML/HTML 5) while recently starting the harverd cs50 course.

    So if any beginners want to work in a team or group let me know!

    submitted by /u/DearYou-
    [link] [comments]

    No comments:

    Post a Comment