• Breaking News

    Saturday, June 8, 2019

    Modern web development Ask Programming

    Modern web development Ask Programming


    Modern web development

    Posted: 08 Jun 2019 02:40 PM PDT

    Hello, I learnt web development back in the day with php and MySQL when php wasn't considered a bad choice.

    Now I'm seeing that most web development involve other kind of things (node, rust, ruby and stuff).

    I want to know what's the modern structure for things now, for example:

    Http server: still Apache? Nginx? Is Mongoose the "in" thing?

    Server side processing (read php replacement): mongoose? Node? Other things?

    How is the frontend integration with these new technologies? Is a frontend framework really needed? I've never liked using frameworks for simple projects.

    Am I making sense? Ofc anything I said could be wrong but I have been a "php developer" too long and I want to modernize.

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

    We all know that Reddit recently updated their database. Do you know which database and schema they now use? Or how their data is generally organized?

    Posted: 08 Jun 2019 02:11 PM PDT

    I'm looking for a Java project to work on for 6-ish weeks, pertaining to a specific list of Java topics

    Posted: 08 Jun 2019 10:43 AM PDT

    Hello.

    In order to be eligible to take AP Computer Science A, a Java-focused class, I need to be proficient in a few topics. Here is what my teacher sent me:

    "I'd want (me) to take a short test just to be sure (I'm) comfortable with these things. It'd take maybe 30 minutes or less. The test would cover the below:

    In Java:

    -Be comfortable with variables, declaring and initializing, and basic data types like int, double, String and boolean

    -Know conditional logic. Be able to write if statements

    -Be able to write some basic for or while loops

    -Be able to write a simple method, that takes some parameters, and returns something

    -Know enough about objects to be able to declare, instantiate them, and use their methods to do things

    -Be able to write a method that accepts an object as a parameter, and uses its methods to do something

    If (I) can do all of these things without references, (I) should be fine to take AP CS A."

    Now, none of these topics are new to me, I'm pretty good with all of them. The last 3 are the ones I have the least experience with, but I do have a vague idea about how to work with methods. A big goal of mine is to get better with Java syntax, because my programming logic knowledge is much better than my syntax. I would really like just one project that I can work on over the next 6 or so weeks that would include all of these topics, but if anyone can recommend something other than just 1 project that could work better to practice these things, that's fine too. Thanks.

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

    What are good websites for sketching ideas/diagrams between two or more users ?

    Posted: 08 Jun 2019 08:56 PM PDT

    What I'm looking for is something like draw.io but where more than one user can interact at the same time with the drawing.

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

    wrapper for essential CUDA algorithms?

    Posted: 08 Jun 2019 06:29 PM PDT

    I'm learning CUDA programming, starting from map, transpose, gather, scatter, stencil, reduce, scan. I know that each of them can be optimized to an extreme, and what I implement are just basic naive implementations. Is there any wrapper out there that already implements these essential algorithms ?

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

    Input question for c

    Posted: 08 Jun 2019 01:39 PM PDT

    Hi all! I am working on a project for one of my programming classes in C, and I have an issue. One part of the assignment is to ask the user to input a number between 1 and 1000, and if it isnt in the range, it prompts the user again and again until you get a number in the range. I used a do-while to accomplish this, and the issue is when a user inputs a correct number on the first iteration, it prompts the user again, even if it is in the same range.

    Here is my code:

    int input1, input2;

    //prompts user for input1 printf("Enter a starting point: "); scanf("%d", &input1); clear\_keyboard\_buffer(); 

    do { printf("I'm sorry, please enter a number less than 1000"); scanf("%d", &input1); clear\_keyboard\_buffer(); } while (input1 < 1 || input1 > 1000); 

    //prompts user for input 2 printf("Enter an ending point: "); scanf("%d", &input2); clear\_keyboard\_buffer(); 

    do{ printf("I'm sorry, please enter a number less than 10000"); scanf("%d", &input2); clear\_keyboard\_buffer(); } while (input2 < input1 || input2 > 10000); 

    Thank you all in advanced.

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

    Is there code I can use to get words to display one at a time, RSVP style? This would be for anki, which I think uses html or css. Complete noob here.

    Posted: 08 Jun 2019 05:20 PM PDT

    Hello, I have already posted this question in the anki subreddits. I hope it is ok that I ask it here as well. I have zero programming knowledge and I am looking to see if something is possible.

    RSVP is a way to speed up reading rate and increase attention. In short, it displays one word at a time in the same spot on the screen so your eyes do not need to move word to word to read. This can increase your reading speed without losing retention rate. Plus, it would stop me from answering a card based on having become familiar with the shape of the text and placement of the cloze statement.

    Here is an example of what that looks like.

    I study through anki, and anything to improve my study rate would be great! Since anki allows a user to format cards with html or css, I am hoping there is some way to apply this idea to card types.

    I have no ability to code, so I did some googling. So far I have found that if I throw some 'typewriter' code into the field portion of an anki card, it works. This makes me wonder if there is code to get the words to display one at a time in the center, and then display the complete statement once done.

    Here is the code that I found worked in anki with a cloze type card. Source is here.

    div { display: inline-block; overflow: hidden; white-space: nowrap; animation: example 2s linear 0s infinite ; } @keyframes example { from { width: 0; } to { width: 150px; } } 

    Here is a random github I found that seems to focused on the same idea, but not specifically for anki.

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

    Best language for MMO dedicated server? (heavy CPU load)

    Posted: 08 Jun 2019 02:37 AM PDT

    TL/DR: Heavy procedural-generation on a dedicated, sharded MMO server for my new game. Client is TCP via Unity C#. Play as server already made in Unity C#. What language has the best performance/scalability for a headless TCP server? Not afraid of learning a new language, but it needs to be the "best overall."

    CPU performance per thread and ease of multi-threaded programming is very important!

    Hi all,

    I'm working on a new, procedural-generation-heavy game that will be single-player/multi-player/MMO. For the single-player/multi-player part, I'm using Unity and Telepathy (C# TCP networking). It's taken a while for Unity/C# to grow on me, but I feel fairly productive in that environment now.

    However, it's clear that for my game to really take off, I'll need to take the dedicated server/MMO bit very seriously, and using Unity for a headless server makes little sense. Since each world is procedurally generated, the CPU load of the dedicated server(s) will be extremely high, and if I have 60+ worlds running at once in the game universe, that's some serious multi-threaded execution/optimization. Each world is almost entirely self-contained, so communication between worlds will be very low, but doing send-new-procedural-terrain-chunks and procedural-action-validity-checks on 20 players per world is pretty significant. I'm willing to throw as much server horsepower as I can at the problem, but choosing the most performant multi-threaded language is a priority in order to save execution time & server energy.

    Here's my programming background:

    I started programming in Borland C. Dabbled in C++ and was forced to make a few webapps in Java. Learned MIPS and 8086 assembly. CPU dense apps in MATLAB & C. I had to learn LabVIEW and wrote a few large (500k lines) apps with it. Some of it was lightning fast. Because multi-threading in LabVIEW is super easy to do, my C equivalent code was close but never as fast. Then Python for 4 years of work, which was irritating but necessary. Maintained some awful legacy Javascript+VB.NET+C# code. Now dabbling in Unity C#, which has slowly grown on me.

    While LabVIEW would be the quickest thing for me to use to get a multi-threaded, CPU-intense, dedicated server off the ground, there's got to be a better option, especially if I ever want someone else to work on it. I'm not afraid of learning a new language, but I need to be convinced that it's the optimal choice if I'm going to go down that rabbit hole, hence this post. I'm not one to learn new languages just for the fun of it.

    Thanks everyone for the direction and input!

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

    What’s the best way to keep a log of data from an API

    Posted: 08 Jun 2019 09:32 AM PDT

    So I want to present data on a site I'm building and it's just a simple call to an API to retrieve the data. However id like to keep a log to show changes in the data over time. What's the best way to handle this? Should I programmatically set a timer or something that every x minutes or so it logs the data in a db? Maybe a cron job (I've been told this is messy and not the best way to handle events like this though)? What's the best way to log data over time that won't necessarily be accessed every day?

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

    Card Linking APIs: Fidel alternative

    Posted: 08 Jun 2019 07:32 AM PDT

    Hi everyone. Fidel isn't a fit for the product we are trying to build due to the flat fee structure - we would prefer a percentage based model. Does anyone know of any alternative APIs that offer transaction notifications? If not, is there any documentation out there on writing our own transaction notification API for VISA and MasterCard?

    MasterCard's Spend Alerts is also unsuitable, as they require registration as a financial institution. If you've got any ideas at all, please leave a comment! Cheers.

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

    how can i get the results of group 1 of a regex match in java script while i can't declare the string?

    Posted: 08 Jun 2019 01:05 AM PDT

    here is the regex demo

    the REGULAR EXPRESSION

    getObj\("Frm_Logintoken"\).value = "(.*)"; 

    this the TEST STRING

    getObj("Frm_Logintoken").value = "3"; 

    i want to get that number only "3" without quotes

    it's in the Group 1 of the matches but i don't know how to get it from that group .

    i can't var myString = "something format_abc";

    because i am doing this to get the value that i don't know !!

    And testing this in console results

    var test = /getObj\("Frm_Logintoken"\).value = "(.*)";/g undefined console.log(test[1]); undefined undefined 

    the same question but in a different way and detailed still unansweredand i have tried

    getObj\("Frm_Logintoken"\).value = "(.*)";`.match(/getObj\("Frm_Logintoken"\).value = "(.*)";/)[1]

    it give me this "(.*)" not the wanted value !!!

    some notes

    1-that value isn't static
    2- i want to make the code works automatic so fetching the line "getObj("Frm_Logintoken").value = "3";"
    from the page code manually is unwanted thing.
    3- i want to make an auto login script without any User intervention.
    4- if you still don't understand the question see the links pls

    thanks

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

    No comments:

    Post a Comment