• Breaking News

    Friday, September 4, 2020

    Would a computer science major be best for me. Ask Programming

    Would a computer science major be best for me. Ask Programming


    Would a computer science major be best for me.

    Posted: 04 Sep 2020 07:57 PM PDT

    So I want to be a programmer when I come out of college. I'm interested in web dev at the moment and I'm currently enrolled in school for computer science. I'm a freshman so I still have time to decide but would this degree be best for me. I'm kind of worry because I'm not the best at math but I'm willing to try to get better. I was just scared that I may not ever get better to actually obtain a CS degree. Has anyone else been bad at math but got a CS degree and how did you do it. Could you basically share your experience?

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

    Do you keep your old/unfinished projects on github?

    Posted: 04 Sep 2020 02:11 AM PDT

    Pretty much what title says. I was wondering whether you guys keep the old projects on your github(or any similar site) or you keep it clean and only have the ones you're proud of?

    Personally i actually do keep most of the projects i've worked on ever since i started programming (~6 years) and even though some of them are terrible (in terms of readability/architechture etc.) for some reason i don't want to remove them (i lie to myself i will update them).

    I wonder if it can be harmful in a way, i.e. recruiter would see old project and would judge my skills based on that.

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

    Can I automate my job?

    Posted: 04 Sep 2020 08:51 PM PDT

    Hey guys! I'm 27 and have a business degree. I'm currently in my first semester of a computer science degree as I would like to become a software engineer.

    I currently work in a corporate role for a huge company. I have a monotonous admin job where I view document uploads by employees to ensure they are filled out correctly, I submit responses based off of information provided, then enter the employees info into a different system to give them new credentials.

    I think the job can be automated and would like to present this to my boss.

    Currently employees take pictures or scan an evaluation scorecard to me.

    My solution: Fillable form with a section for digital signature by the evaluator. The bot could scan the submission and automatically respond based off of whats filled out.

    Then the algorithm stores the form in the appropriate folder.

    The next thing would be entering the employee info into a completely separate system to give them their new credentials. I'm sure this is possible but what are your thoughts?

    I would like to create a bot to replace me and earn a role as a software engineer for this company. Any thoughts or help would be appreciated!

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

    New to Python, and need a little help.

    Posted: 04 Sep 2020 12:13 PM PDT

    So I am doing HW for my intro to python class, and am stumped on a question:

    Write code that determines the number of full days represented by the number of hours stored in the variable

    hours 

    and stores that value in the variable

    full_days 

    . For example, the number of full days in 50 hours is 2. Ignore any leftover hours that don't contribute to a full day. Assume the value of

    hours 

    has already been initialized.

    I'm sure it is a really simple answer that I am overthinking, but I would really appreciate some input!

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

    How should I go about making a recommendation algorithm for similar videos

    Posted: 04 Sep 2020 09:48 PM PDT

    I am creating a REST API in node/express using mongodb (mongoose) that needs to be able to return a list of similar videos based on the requested video page. There is no data that tracks a user's viewing habits so the similar videos should be based only on data from the video page requested. For reference here is a copy of the video model. As you can see each video can have many different properties and depending on how the video was added many can be `null`.

    This is my first time writing an algorithm like this so I am not sure where to begin. I would appreciate if somebody could point me in the right direction.

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

    Atomic Transactions and REST API Performance

    Posted: 04 Sep 2020 10:18 AM PDT

    Hi, I have a question about the potential impact of enabling Atomic Transactions.

    Let's say I have a view that updates a user's profile. I have another view that goes through all the users (SELECTs all the users) and return some aggregated information. Both views are in an atomic transaction decorator (context: Django). If a user updates their profile and, a few milliseconds later, there's a request for the aggregated information, will the latter request have to wait for the first to finish before getting the data from the DB?

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

    Excel and SQL - Or how to make an excel that imports easily

    Posted: 04 Sep 2020 08:45 PM PDT

    I am creating a database in an excel, each row represents an image and the columns contain various information about the image. One column I would like to dedicate towards keywords to aid in searching later. These images need to be able to filtered by year/day/name/ and various other sort orders. I know very little of programming but understand that excels can be imported to SQL databases. I am trying to learn more about how to best layout this information on the assumption it gets imported into a SQL database later.

    Does anyone know a good resource for this? I don't want to ask a million small questions, but am struggling to find an online resource that properly answers the question without just diving into code. Which I have learned a lot from but, I am trying to find answers to questions like:

    Will I have issues if one cell contains several keywords? If so are commas needed, or do they simply need a space? What if cell contains a link to another cell within the same workbook, will it pull the keyword from the linked cell?

    What I am trying to do is build an excel that will take the least amount of work possible to import later on. If this makes zero sense, please kick me out. At least I know where I stand. I appreciate any and all who took the time and read/respond.

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

    Need help setting up website change notifications

    Posted: 04 Sep 2020 08:00 PM PDT

    Okay, so I am a complete beginner with next to 0 knowledge about coding or raspberry pi but I am looking for help to learn how to do what I want to.

    *Note: I'm not asking you to do it for me, but I'm asking for you to help me figure out how to learn. If you know of a video tutorial / blog post with step-by-step instructions on what to do (preferably with explanations as to why each step is necessary), that would be great!

    I'm wanting to have my raspberry pi run 24/7 and look at specific webpages on certain websites. When there is something changed (for example, an item added to an online store), I want to receive a notification (either on my phone or just an email would suffice).

    Like I said, I have no idea where to start. I have done extensive searching in the forums and this subreddit and found several threads, but I simply don't understand/know how to set up/do what the people there are saying to do.

    For example, here a user mentions,

    "make in bash with wget or curl. Just loop through an array of websites and grab the URL. Save output to a temp file. If non temp file doesn't exist save it. If it does exist diff files or md5 them and alert at differences."

    But I don't know what this means or how to do it.

    Any direction would be extremely helpful! Thanks!

    submitted by /u/1phenylpropan-2amine
    [link] [comments]

    Building a Search Engine

    Posted: 04 Sep 2020 06:35 PM PDT

    I'm creating a website to make it easier for people to shop for healthcare. But I need help building the search engine. One that allows you to search by hospital and location.

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

    Is there a tool or an API that measures the driving distance from point A to point B?

    Posted: 04 Sep 2020 05:46 PM PDT

    I'm creating a delivery service website that will employ a delivery fee calculator which computes the driving distance from point A to point B. I've been looking for an easy to use tool that does that for me and I'm having a hard time finding one.

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

    "single int vlaue to represent a date, using mixed-radix number"

    Posted: 04 Sep 2020 04:01 PM PDT

    https://i.imgur.com/j3zf7ma.png

    Can anyone help me understand this? taken from java alogithms 4th edition, chapter 1.2 page 91.

    Basically I want to understand and explain the difference? how can this code take in just one digit?

    Taken from the book:

    "right uses only a single int value to represent a date, using a mixed-radix number that represents the date with day d, month m, and year y as 512y + 32m + d."

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

    Is there a program or script that can watch TV shows and count every instance of a specified word or phrase?

    Posted: 04 Sep 2020 03:58 PM PDT

    E.g. It listens for the phrase "American dream" and then indicates the number of times that phrase is said per episode.

    This is for academic research. Many thanks!

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

    I want to make a program to automate reorganization of a text file.

    Posted: 04 Sep 2020 03:42 PM PDT

    Ok, so the title is a bit weird (english is not my first language).

    Anyways, I am making a project in which I require a lot of digital filters. These filters use coefficients, which I now have stored in a text file. The problem is, I cannot just copy and paste these coefficients into my project file, because they are not written in C syntax.

    I have around 4000 of these coefficient values and rewriting them manually would take quite some time (8-12 hours).
    I figured it shouldn't be too hard to write a program that would do this for me, although I have zero experience with this kind of programming.

    Here are my values stored in a text file:

    Numerator

    b3 2,449622763746036820E-7

    b2 7,348868291238110470E-7

    b1 7,348868291238110470E-7

    b0 2,449622763746036820E-7

    Denominator

    a3 -9,751802955156090750E-1

    a2 2,950049679327467980E0

    a1 -2,974867424113647910E0

    a0 1,000000000000000000E0

    What I'm trying to achieve is this:

    b3[0]=2,449622763746036820*pow(10,-7)

    b2[0]=7,348868291238110470*pow(10,-7)

    b1[0]=7,348868291238110470*pow(10,-7)

    b0[0]=2,449622763746036820*pow(10,-7)

    a3[0]=-9,751802955156090750*pow(10,-1)

    a2[0]=2,950049679327467980

    a1[0]=-2,974867424113647910

    a0[0]=1,000000000000000000

    The next set of values should be written with [1] instead of [0]. Like this:

    b3[1]=2,449622763746036820*pow(10,-7)
    ....

    The code above is for one filter only. I have 499 more sets of values like this written in the same text file.

    Could any of you help me with this?

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

    [C] Using Functions to create global Structs?

    Posted: 04 Sep 2020 02:42 PM PDT

    Hello. I'm working on a project where I'm making a board game/RPG- like game. One thing I'm trying to see is if I can use functions to create enemies for the player to face when they land on a tile. And I'm having trouble with that. I made a function that creates an enemy but that's only local to that function. Any tips or suggestions for making this work?

    Here's my pseudocode:

    #include <stdio.h>

    #include <ctype.h>

    #include <time.h>

    #include <stdlib.h>

    struct person {

    int health;

    char name[20];

    int attack;

    };

    //I plan to use this to make enemies for the player

    struct person player;

    int role_die() //rolls die.

    int board() //Uses roll die to generate tiles. One of which is a Battle Tile where the player fights an enemy

    int create_enemy() // I want to make a version of this that gets called whenever a player lands on a battle tile that creates a new enemy. I hope to expand this so it can make its own enemies through a dice roll rather than be pre-made by me.

    {

    struct person enemyOne;

    enemyOne.name = "goblin";

    enemyOne.health = 2;

    enemyOne.attack = 2;

    }

    As you can see, create_enemy is local and can't really be used outside of that. Is there a way I can make it so it creates global structs of enemies? I really don't just want to make an entire file full of enemies and have it pull from that.

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

    Can you be a programmer with arthritis or carpal tunnel syndrome?

    Posted: 04 Sep 2020 05:57 AM PDT

    I'm getting tested for both.

    submitted by /u/Fluffy-Estate
    [link] [comments]

    Are employees at the DOD pissed that they have to use Azure? My experience has been that it is 5-10 years behind AWS in UI & features

    Posted: 04 Sep 2020 05:32 PM PDT

    Java - Builder Pattern One to Many

    Posted: 04 Sep 2020 01:06 PM PDT

    Inherited a poorly designed project at work and got it up and running but stuck on one part. I can't go into too much detail because of NDAs. Gist of the project is I'm taking form data and passing it along to the client through an API connection.

    The form itself has a section where the person can fill out who they want to receive the info once it's received on the client's end. But I can only include one destination user per request. So I might need to send a request multiple times with the same data except for who the destination user is. Right now I have it functional and able to get the job done but it's janky.

    What I'm wondering about is if I'm able to have the builder take the form info and return one to many objects based on how many destination users there are. My knowledge on builders is still raw at the moment.

    Any information you can lend me or even pointing me to where I could find this info would be greatly appreciated.

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

    Different guessing strategies?

    Posted: 04 Sep 2020 12:54 PM PDT

    Hi! So I just started classes with programming and I have an assignment (lol). The scenario is Player A thinks of a number from 1-100 and I need to identify 5 different guessing strategies that Player B could use to guess Player A's number. Can someone help me? Thank you everyone

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

    Really important question

    Posted: 04 Sep 2020 11:40 AM PDT

    So where does everybody stand as far as coffee/caffeine? Are you more cold brew, tea, energy drinks, too hard-core to deal with those punk ass stimulants?

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

    Java coding challenge stuck with a bug please help

    Posted: 04 Sep 2020 11:37 AM PDT

    Hi, I am trying to build a program that would enable user build two circles and create a point, then, determine the position of this point regarding both of the circles. My bug is, I do not know why, but for some reason the distance calculator between the point and the circle's midpoint is not working accurately, I have calculated the values myself and I believe there is a problem there, this is very important since the calculated value determines the position of the point regarding the circles (outside of the two circle for ex). Please help me solve this problem, what am I doing wrong ? Thank You

    Edit: Please do not mind the cases, I have not completed them yet, I am aware of that. However, I think the problem is with the distance calculator from the first place

    import java.util.Scanner; // Import Scanner class (Used for Input)
    class Circle {
    public void run() {
    // Implement program for the assignment
    /*
    Current Errors in the Program:
    1 - The calculator for distance between circle's center and the point is incorrect
    */
    //Circle 1 inputs from user
    Scanner x1 = new Scanner(System.in); // x1 (midpoint 1st circle)
    int coordinatex1;
    Scanner y1 = new Scanner(System.in); //y1 (midpoint 1st circle)
    int coordinatey1;
    Scanner r1 = new Scanner(System.in); //r1 (radius 1st circle)
    int radius1;
    //Circle 2 inputs from user
    Scanner x2 = new Scanner(System.in); // x2 (midpoint 2nd circle)
    int coordinatex2;
    Scanner y2 = new Scanner(System.in); //y2 (midpoint 2nd circle)
    int coordinatey2;
    Scanner r2 = new Scanner(System.in); //r2 (radius 2nd circle)
    int radius2;
    //Point inputs from user
    Scanner px = new Scanner(System.in); // x2 (midpoint 2nd circle)
    int pointx;
    Scanner py = new Scanner(System.in); //y2 (midpoint 2nd circle)
    int pointy;

    // Interface for Circle 1 (Enter midpoint coordinates and radius of circle 1)
    System.out.println("Enter x-coordinate of 1st circle's midpoint ");
    coordinatex1 = x1.nextInt(); // Storing the x1 input
    System.out.println("Enter y-coordinate of 1st circle's midpoint ");
    coordinatey1 = y1.nextInt(); // Storing the y1 input
    System.out.println("Enter radius of 1st circle ");
    radius1 = r1.nextInt(); // Storing the y1 input

    // Interface for Circle 1 (Enter midpoint coordinates and radius of circle 1)
    System.out.println("Enter x-coordinate of 2nd circle's midpoint ");
    coordinatex2 = x2.nextInt(); // Storing the x2 input
    System.out.println("Enter y-coordinate of 2nd circle's midpoint ");
    coordinatey2 = y2.nextInt(); // Storing the y2 input
    System.out.println("Enter radius of 2nd circle ");
    radius2 = r2.nextInt(); // Storing the r2 input
    // Interface for Point (Enter coordinates of the point)
    System.out.println("Enter x-coordinate of the point ");
    pointx = px.nextInt(); // Storing the x-coordinate of the point
    System.out.println("Enter y-coordinate of the point ");
    pointy = py.nextInt(); // Storing the y-coordine of the point

    // Finding distance between circle 1 and point
    double distanceC1andP;
    distanceC1andP = Math.sqrt((pointx - coordinatex1)^2 + (pointy - coordinatey1)^2);
    System.out.println("Distance between the 1st circle and the point is (from midpoint) " + distanceC1andP);
    // Finding distance between circle 2 and point
    double distanceC2andP;
    distanceC2andP = Math.sqrt((pointx - coordinatex2)^2 + (pointy - coordinatey2)^2);
    System.out.println("Distance between the 2nd circle and the point is (from midpoint) " + distanceC2andP);
    // Deciding whether the point is inside, on or outside C1
    //Final decision about points position regarding both circles\
    //Ex: Is it inside both circles ? Is it in C1 and outside of C2 ?
    if ( (distanceC1andP < radius1) && ( distanceC2andP < radius2 ) ) {
    System.out.println("Point is inside of both circles ");
    }
    else if ( (distanceC1andP == radius1) && (distanceC2andP == radius2) ) {
    System.out.println("Point is on both circles ");
    }
    else {
    System.out.println("Point is outside of both circles ");
    }
    }
    public static void main(String[] args) {
    (new Circle()).run();
    }
    }

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

    Legal requirements for a website with purchase option (EU/Austria)

    Posted: 04 Sep 2020 07:23 AM PDT

    I'm planning to develop a website where users can buy something which will give them premium features. But what are the legal requirements? I'm planning to use stripe for payments. Is there anything I have to know regarding taxation and are there any problems if you are under the age of 18?

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

    Any lighter alternatives to Facebook customer chat on business websites?

    Posted: 04 Sep 2020 10:12 AM PDT

    The FB customer chat plugin has drastically slowed down the mobile version of a site we've been working on as much as +3s, we've tried to Minify and did other optimizations on some of the code but have problems with errors and bugs.

    Now we're trying to find an alternative to FB chat, something with automated features, better yet, a "bot" system altogether.

    I'm not too keen with messaging systems, I actually only know of FB, any recommendations will be of great help.

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

    What should I know to develop my own app?

    Posted: 04 Sep 2020 10:04 AM PDT

    How to get .hover to behave the same on mobile Android and iOS?

    Posted: 04 Sep 2020 09:56 AM PDT

    Hey, folks!

    I've been Googling for hours and it seems my issue needs a different solution than the ones I've found on online forums like Stack Overflow, so I'm hoping someone here might be able to point me in the right direction.

    Here is my site: aishawithaneye.com

    On Android, the .hover works the way I want it to: one tap will cause the .hover to appear (a speech bubble) and then the second tap will cause the link to open. Tapping away will also close the speech bubble.

    On iOS, one tap will cause the .hover to appear and immediately open the link. If the user goes "back" the hover state will still be activated, tapping away doesn't close it. Tapping on another link will not close it either, but open another speech bubble, open that link, and if the user goes "back" they will see both .hovers activated. It gets ugly really quick.

    Does anyone have any ideas on how I can make the iOS version behave more similarly to the Android version? If I can only choose to fix one thing, it would be when the user goes "back" the .hovers are reset, but, ideally, I like the way Android requires two taps to open .hover links as well, so the user has time to read what they're about to open.

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

    No comments:

    Post a Comment