• Breaking News

    Thursday, January 31, 2019

    What language is being used here in this youtube video about job automation? Ask Programming

    What language is being used here in this youtube video about job automation? Ask Programming


    What language is being used here in this youtube video about job automation?

    Posted: 31 Jan 2019 08:28 PM PST

    I was able to get a decently clear frame here: https://imgur.com/a/U4X2pH0

    edit:

    vid here

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

    Stumped about flowcharts.

    Posted: 31 Jan 2019 02:00 PM PST

    I submitted an assignment for a class, and got a 4/20-- I was kind of confused as to why, and I don't really have a frame of reference for programming, as it is my first computer science course. I reattempted to make the flowchart in response to this:

    Management would like a printed report that shows the total bonus pay awarded based on the number of years a person has worked for the company and the total bonus pay.

    1. The data file is on a disk.

    2. The file contains the required fields (date of hire and total annual pay) and may include fields that are not needed for this problem.

    3. The bonus for those with 30 or more years of service is 10% of total annual pay.

    4. The bonus for those with at least 20 years of service but less than 30 years is 6% of total annual pay.

    5. The bonus for those with at least 5 years of service but less than 20 years is 3% of total annual pay.

    6. An employee who has not worked for the company for at least 5 years receives a bonus of $200.

    7. For this assignment the data file must be processed one record at a time.

    Here's the flowchart I made in response to the question. Not sure why it's graded so low.

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

    How to read a pickled string in c++?

    Posted: 31 Jan 2019 06:40 PM PST

    I'm currently working on a program that receives python pickled strings from an AMQP messaging service. so far in c++ i have captured the message and i have it displaying, but it is dislplaying as gibberish with a few english letters. Whats the best way to unpack this data?

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

    What is the most powerful drawing software for mathematical and scientific purposes?

    Posted: 31 Jan 2019 02:26 PM PST

    I'm thinking along the lines of Asymptote, matplotlib, or stuff like that.

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

    Is it possible to open an IDE in your primary OS from within a Virtual Machine (separate OS)?

    Posted: 31 Jan 2019 05:19 PM PST

    My PC is running Windows 10. For the purposes of a university class I'm required to use an Oracle VM Virtual Box which is running Ubuntu. This is where I'll need to compile and run code.

    However, the text editors that came with the VM I was given are Sublime, Emacs, and Vim. On my main OS (Windows 10) I'm using Atom. Is there a way to open Atom (on my main OS) from within Ubuntu (virtual machine)?

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

    What was the best book you read on stucturing databases?

    Posted: 31 Jan 2019 08:06 PM PST

    I went to a bootcamp that primarily focused on front end development. We learned a bit of ruby on rails but database building was always 'just do what makes sense'. What book did you all read that made databases click?

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

    What laptop would you suggest me to programming?

    Posted: 31 Jan 2019 08:41 AM PST

    I'm learning programming at the university but a few days ago my laptop was broken. I had a HP 250 G2 one but now I would like to buy something else. I'm not really sure about what system is better for programming (Windows/Linux or MacOs) , or it depends on the person. What you would suggest me to buy? Laptops which are based on the system of Windows/Linux (so not MacBooks) have a favorable price, interesting me. My budget is $700-$750.

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

    Running two different versions of Python at the same time

    Posted: 31 Jan 2019 07:03 PM PST

    I currently have Python 3.7 installed on my laptop, but I want to use 3.6.4 in order to play around with a Discord bot. I am told I can use both versions at the same time, but have absolutely no idea on how to do this? Does anyone know how I can achieve this? Thank you in advance.

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

    How does SSH shares data continuously​?

    Posted: 31 Jan 2019 06:30 PM PST

    Hi, I know the basics of ssh i.e. how does it encrypts every message sent to the server, but I'm wondering how does ssh encrypts data that it's send continuously, like a program sending data all the time. Does it encrypts every line received (after a \n) or it waits till the message is written to encrypt it and send it?

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

    Need help with Javascript

    Posted: 31 Jan 2019 09:35 AM PST

    I'm trying to create a custom discord bot but i can't seem to make the +fanfic command to work

    What am i doing wrong?

    const Discord = require('discord.js');
    const client = new Discord.Client();

    client.on('ready', () => {
    console.log(\Logged in as ${client.user.tag}!`); client.user.setGame(`Destiny 3`);`

    });

    function doMagic8BallVoodoo() {
    var rand = ['Mo Bamba', 'Sicko mode',];
    return rand[Math.floor(Math.random()*rand.length)];
    }
    function doMagic8BallVoodoo1() {
    var rand = ['Cayde-69', 'Ikora', 'Cayde-6', 'Uldren Sov', 'Petra', 'Shaxx', 'Eris Morn', 'Amanda Holliday', 'The drifter', 'Ada_1',];
    return rand[Math.floor(Math.random()*rand.length)];
    }
    function doMagic8BallVoodoo2() {
    var rand = ['getting','riding','killing', 'slapping', 'becoming',];
    return rand[Math.floor(Math.random()*rand.length)];
    }
    function doMagic8BallVoodoo3() {
    var rand = ['a dead horse','a chicken','Cayde-6','Vex','Fallen','Taken','a cow','some random dude','some random dudette','the Traveler', 'kittens', 'a ship','the Last Word',];
    return rand[Math.floor(Math.random()*rand.length)];
    }

    client.on('message', msg => {
    if (msg.content === '+mobambaorsickomode')
    {
    msg.reply('' + doMagic8BallVoodoo());
    }

    if (msg.content === '+whatmustido') {
    msg.reply('Respecc Cayde and Moira');
    }

    if (msg.content === '+iscaydealive') {
    msg.reply('no');
    }

    if (msg.content === '+ismoiraalive') {
    msg.reply('yes');
    }

    if (msg.content === '+crusade') {
    msg.reply('WE MUST START A WAR AGAINST THOSE WHO CALL THEM SELFS GAYS');
    }

    if (msg.content === '+fanfic')
    {
    msg.reply('' + doMagic8BallVoodoo1 + doMagic8BallVoodoo2 + doMagic8BallVoodoo3());
    }

    submitted by /u/0li4
    [link] [comments]

    [ASM] how does register renaming affect flags and vice versa in modern x86 cpus

    Posted: 31 Jan 2019 05:26 AM PST

    For instance is a modern x86 cpu capable of parallelizing adc instructions if 4 or more (in two independent blocks) are used with different registers and combined later or is the flag dependency blocking the pipeline from running in parallel?

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

    GitHub classroom question

    Posted: 31 Jan 2019 04:59 AM PST

    If I wanna check another students repo, would my professor get notified ?

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

    Recommendations for a C++ Style Checker

    Posted: 31 Jan 2019 08:42 AM PST

    Not sure if this is the right subreddit for this because it's tool related not code related but I'll give it a try.

    I'm looking to hook up a C++ Style checker to Jenkins and fail the build if a file fails the style check. I don't need any other static analysis stuff besides style.

    Requirements:

    - Configurable (We have a style guide already which we'd like to follow as closely as possible)

    - Just gives error messages instead of trying to reformat the code automatically (Error messages like "Too much indent on line 10" or "Expected newline before '{' in line 50" or whatever, just basic stuff people can read).

    - Can hook up to CI (so basically, can run from the command line and give a non-zero exit code if there's style issues. So, no IDE plugins basically.)

    Does anyone know of any tools that could do this? I've looked around a lot, but haven't found anything good. Some I've rejected:

    - cpplint (not configurable enough)

    - astyle (wants to reformat my code instead of just giving me errors)

    Any Advice would be appreciated. Thanks!

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

    How to time event in lua script ?

    Posted: 31 Jan 2019 08:32 AM PST

    Hi guys, Im fairly new to programming in lua so im just writing an extremely easy script.

    The script will count how many time a LED flashes and report the number. If the LED is off for more than 1 seconds, it reset the counter and start to count again if LED is on.

    I am not too sure about the timing part on my script. I used arduino to simulate the LED flashing. This is what I have so far. It works (kinda) but will also show count wrong once in a while.

     function counter() local t1 = os.clock() while (ReadADC1()>48) do local t2 = os.clock() local dt = t2 - t1 t1 = t2 local ledValue = ReadADC1() if ( ((ReadADC1() >= OnThreshHold) )) then-- if led is on, just count, everything else will reset counter ledCounter = ledCounter + 1 vmsleep(30) else ledCounter = 0 end return ledCounter end 

    You can ignore t2 and t1 since i used it in previous version with timing. Turn out it not very necessary (i think) when I have vmsleep()

    Counting still give wrong number every once in a while since I didnt specify the timing. I think that is what wrong with the script.

    Adruino code is just write high and low on led pin with 500 and 100 interval. Break interval is 2000.

    Any help is appreciated

    this is the output to sieral port

    0

    0

    3

    3

    3

    3

    3

    3

    3

    3

    3

    3

    6

    6

    6

    0

    As you can see, the correct output suppose to be 3, but it didnt reset but add 3 more to counter before it reset to 0

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

    What is the name of the AI model that can classify items into categories?

    Posted: 31 Jan 2019 08:20 AM PST

    I'm looking for a name/Wikipedia article so I can understand the math.

    Unfortunately the language I am using doesn't have built in libraries for this, I will need to write my own calculations.

    So far I've done the data mining, talking 1000 items(human sentences) that have already been categorized into 50 different items, and I have a table with-

    Category vs frequency of word use.

    Originally thought I could do probability of word times frequency minus false positive, but it only worked on 1/4 new entries.

    Anyone know suggestions for the Math?

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

    what does (*( uint8 *) (&(variable_name)) do?

    Posted: 31 Jan 2019 07:21 AM PST

    Hello redditers, so i know it makes a cast from whatever variable_name's type is and makes it uint8, but why the * and &?

    Edit: forgot to mention, the language is C.

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

    Why is bogosort called bogosort?

    Posted: 31 Jan 2019 12:02 AM PST

    Best approach when importing ugly column names

    Posted: 31 Jan 2019 04:20 AM PST

    I have an application that is going to periodically import CSVs from another application.

    The other application can't be edited and uses inconsistent column names and a different convention to what I would choose if I were to start from scratch. For example...

    Order_No (title case) I'd favour order_id

    DESPATCH_STATUS (uppercase, debatable misspelling) I'd favour dispatch_status

    Required_Time_T, Required_Time_F (abbreviated, not clear what this is)

    I'm trying to make a judgement call on whether to...

    a) rename all the columns nice names in my database, then write all the logic to transform them.

    b) make all of my column names match the current application, which will be uglier but possibly more robust.

    Has anyone got any experience or war stories on why I should / shouldn't do one of the above options?

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

    Is there a Programming Lang in which variables can be limited to range of possible values

    Posted: 31 Jan 2019 04:08 AM PST

    I having hard time formulating google search request and find anything useful. Here is what I'm looking for in pseudo code:

    # User inputs value which is limited to 0..250, otherwise crash a:[0..250] = input() # compiler now knows that b's possible value range is 50..300 b = a + 50 # compiler knows `c` is in range 0..10 c = a // 25 # compiler knows that output of program is in range "0..3000 with step 25" print(b*c) 

    I'm looking for real languages, esoteric languages, articles and papers on similar ideas. Anything really.

    submitted by /u/891st
    [link] [comments]

    What are the tools available to create a cross platform desktop application?

    Posted: 31 Jan 2019 03:41 AM PST

    I'm primarily a c# developer, but I have a fair knowledge of Java and C++. I'm planning to develop a network based application with a lot of drawable content. I was checking for answers on Google and I was able to find a few.

    • Mono
    • c++ and qt
    • JavaFX
    • ElectronJS

    I think JavaFX is no longer receiving any updates from oracle, and I hate web development. Would I still be comfortable with ElectronJS? Are there any other options I might have missed out on?

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

    Favicon shows in Firefox but not in Chrome and Opera, tried everything I could find.

    Posted: 31 Jan 2019 02:59 AM PST

    Hello,

    just as the title says. Here are some thing I tried:

    - .png .ico and link from an online upload.

    - Different <link> formats and order inside of it.
    - Changing name of favicon to myfavicon or other names.
    - Ending filepath with v?=2.
    - Deleting two cache and chache journal in Chrome -> default folder. Also cleaning cache from history.
    - Uploading the picture in some coding language that end in 64, forgot which one.
    - Tried different pictures.

    There might be some things I'm forgetting. So I have no clue what's wrong with Chrome and Opera but it doesn't affect Firefox.

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

    How to manage multiple CLI microservices locally?

    Posted: 31 Jan 2019 02:43 AM PST

    At my job we have a team developing some microservices. We run them each in a different CMD window. Most of the time I have 4-6 of them running + my own IDE to work on my stuff that utilises them.

    It can get tedious running that many CMD prompts off on the side while trying to do my own thing.

    Do you guys have any suggestions, tools, GUI's designed to easily manage/start/stop/restart/etc multiple microservices running in different CMD windows? Trying to find some kind of local tool I can run that lets me manage and see their status?

    (they're Java)

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

    Why doesn't my boolean work? (I highlighted the non-functioning line)

    Posted: 30 Jan 2019 11:55 PM PST

    package winw2;

    import static java.awt.Color.RED;

    import java.awt.Graphics;

    import java.awt.Graphics2D;

    import static java.awt.MouseInfo.getPointerInfo;

    import java.awt.PointerInfo;

    import java.awt.event.MouseEvent;

    import java.awt.event.MouseListener;

    import java.awt.event.MouseMotionListener;

    import java.awt.geom.Ellipse2D;

    import javax.swing.JPanel;

    public class PPanel extends JPanel implements MouseMotionListener {

    boolean over = false;

    Ellipse2D.Double ell = new Ellipse2D.Double(100, 100, 60, 60);

    public void mouseDragged(MouseEvent e) {

    }

    public void mouseMoved(MouseEvent e) {

    over=false;

    PointerInfo mus = getPointerInfo();

    over= ell.contains(mus);

    }

    public void paintComponent(Graphics g) {

    repaint();

    Graphics2D g2 = (Graphics2D) g;

    g2.setColor(RED);

    g2.fill(ell);

    }

    }

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

    No comments:

    Post a Comment