• Breaking News

    Tuesday, August 28, 2018

    Which IDE/editor is this? Ask Programming

    Which IDE/editor is this? Ask Programming


    Which IDE/editor is this?

    Posted: 28 Aug 2018 05:05 PM PDT

    Which IDE/editor is this?

    https://imgur.com/a/TbUYOFd

    This is from Traversy Media's video here: https://www.youtube.com/watch?v=RVMHhtTqUxc&t=523s

    Never seen this before, but then again, I'm new to using MacOS. Thanks!

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

    Were to start on making custom drivers

    Posted: 28 Aug 2018 08:40 PM PDT

    I'm a digital artist and 3D modeler and general computer graphics nut, so I have a lot of USB devices. Two drawing tablets, a 3D mouse, Two keyboards one just for macros, stuff like that. I have long had minor issues with functionality of some of these with certain applications, but the problem is kind of coming to a head. This post could get long, so strap in. I'm going to start with a description of my setup. I have a older Wacom Cintiq which is my main drawing device, a Wacom Intuos Pro that I map to another monitor where I keep all my tools and pallets and such, a 3D Connexion SpaceNavigator, a Corsair Strafe and then another mech keyboard that I don't really plan on messing with too much as it is my daily driver. Now most of this works well enough out of the box, but it means having many, MANY, individual programs handling each device. That being said there is also some functionality lacking that I think should reasonably exist. First of all I was gifted a Wacom Pro Pen 3D, which unfortunately is not compatible with either of my devices. I will hopefully own a device it is compatible with at some point, so I held onto it. My tablets see the pen enough to know to pop up a message that says the pen is not compatible, which makes me believe it is a software block rather than a hardware issue. The next issue I encountered is Photoshop's, and other software, inability to take analog input. There's a great video of a guy who has made a custom DLL for his setup to add some custom functionality with foot pedals and such. He dose not provide a download to learn from and I have reached out to him for additional info to no avail. I have looked into alternate drivers for the 3D mouse and such to see if I could at least map some of the axes to give continuous keystrokes to increase brush size and smoothing. After throwing myself at the issue for a few days and getting nowhere fast I began to rethink it all. I realized the best thing for me could possible be to build a custom unified driver (I thought this without having any idea how complicated that process might be) that could run all of these in the way I want, and provide customization to that functionality. I also thought this would be an opportunity to get back into some more complicated coding projects, and perhaps make a larger scale project that could be used by many people in a similar position as me. Basically I am wondering where to start on this. I honestly don't know if the best thing for me is a custom driver, or DLL or whatever. I've looked into autohotkey and some generic joystick drivers, but I have yet to find something that actually provides the type of control I need with relative ease, so I figured, if it's going to be complicated anyway, may as well do it right.

    TL;DR I have a lot of USB things that I'm not quite happy with and want to know what it takes to make my own driver to rule them all.

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

    What prerequisites are needed for Reverse Engineering?

    Posted: 28 Aug 2018 01:28 PM PDT

    What prerequisites are required to be a competent reverse engineer and where can I learn those prerequisites (besides "the internet")?

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

    Learning Python

    Posted: 28 Aug 2018 07:08 PM PDT

    In a function a python function I am looking to take a list of strings returns the concatenation of the strings in reverse order. Any and all help is much appreciated...

    def good_list(R)
    ......

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

    How to comply with open source libraries and theme?

    Posted: 28 Aug 2018 02:58 PM PDT

    So I plan to license my app under GPL3. The library I'm using is MIT, and binds to gtk which is also MIT. So far so good. But I would like to distribute a gtk theme with my app that's GPL2. I have read that GPL 3 and 2 are incompatible. Can I not do this? Furthermore, when I distribute my app, do I need to distribute a file that contains the license notices of the open source libraries I use or something? And what about my dependencies dependencie's

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

    What is the best algorithm to be used for patient appointment systems in hospital?

    Posted: 28 Aug 2018 10:49 AM PDT

    We're trying to develop patient appointment scheduler for medical institutions as our final year project and stuck in finding which algorithm is best for this purpose.

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

    Some way to use the mouse commands without interrupting mouse use?

    Posted: 28 Aug 2018 04:45 PM PDT

    For example, clicking on a window while the person is still using the mouse and dont get interrupted, the program to click is directx

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

    Why search engines like Altavista or lycos don't use spiders like google did to become as good as google?

    Posted: 28 Aug 2018 04:14 PM PDT

    what is needed to compete against google?

    google needs a little bit of competition, to become more customer friendly. because now they are becoming as cold as microsoft.

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

    [Java] Double not behaving how I expect?

    Posted: 28 Aug 2018 11:33 AM PDT

    I am doing a simple calculator to get more familiar with Java, and my average function isn't working how I think it should.

     Scanner userInput = new Scanner(System.in); // Declaring all variables int first; int second; int third; int sum; // Reading the inputs of the user System.out.println("Enter the first number "); first=userInput.nextInt(); System.out.println("Enter the second number "); second=userInput.nextInt(); System.out.println("Enter the third number"); third = userInput.nextInt(); // Doing the calculations sum = first+second+third; double average = (sum/3); // Output the results System.out.println("The Numbers were " + first + " " + second + " " + third); System.out.println("The sum of the numbers is " + sum); System.out.println("The Average of the numbers is " + average); 

    If I input the numbers 8, 10, 20 I should get 38 as the sum, and the average is 12.66

    My actual output is 38 as the sum, and 12.0 as the average.

    *EDIT\* I realized my mistake. I did not do "double average = (sum / (double)3);

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

    Where to Start? What language to learn?

    Posted: 28 Aug 2018 06:06 AM PDT

    I am currently a BMS engineer using control software for HVAC units etc. At the moment the most common equipment that I work on is Trend; however, I would like to start moving into Delta equipment. The problem here is that Delta is programmed in code rather than logic graphics.

    So for better progression I need to start learning code. What language would you recommend starting with?

    After some looking around my current list is:

    • Python
    • Java / JavaScript
    • C#
    • C++

    Any help is greatly appreciated as I have no idea where to start.

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

    Explain reduce and concat array methods in Javascript

    Posted: 28 Aug 2018 09:24 AM PDT

    I have a function that combines two arrays..

    let arr1 = ["a", "b", "c", "d", "e"]; let arr2 = [1, 2, 3, 4, 5];

    let arrayCombined = arr1.map(function(curr, i){ return [curr, arr2[i]]; }).reduce(function(a,b){ return a.concat(b); })

    I'm having trouble understanding how reduce and concat work in this example. For example, without reduce the function will output five copies of the array, but once added it only produces one. Guess I'm trying to understand how we go from 5 copies of the array, to one combined array from reduce .

    Thank you in advance.

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

    When learning a language how long do you spend on studying the syntax/semantics and becoming fluent vs. getting some real exposure to the code in real world examples?

    Posted: 28 Aug 2018 03:26 AM PDT

    At the moment I feel like I sometimes spend too much time on either end of the spectrum. I don't enjoy the feeling of just studying the language for academic sake, but then I also don't enjoy struggling through a language having to spend most of my time refereeing to Google/Stack for everything. How do you find that perfect mix, how do you ramp up on a new language that's sustainable?

    Thanks!

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

    Migrating an MS access application to a web platform.

    Posted: 28 Aug 2018 04:52 AM PDT

    We have a small in-house written MS Access application, that we use to log customers, orders, production stages, billing, etc.

    This was written about 8 years ago, and the person who made it initially and, lately I, have been supporting and developing it since. But it's getting clearer each day that we need something more modern to replace it.

    So the plan is to slowly transition to a web based app. This will be my first meaningful web project, so I have no idea what the tools available are, or their capabilities.

    So where do I begin?

    Thanks

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

    What’s with startups giving everyone fancy titles?

    Posted: 28 Aug 2018 07:45 AM PDT

    I recently quit my job because it wasn't a good fit for me anymore and I'm looking around for something new. Since I have a lot of experience a number of startups have come knocking saying that they could use someone with experience to help them out. One in particular has a full third of the company with CxO titles and every single one of them is fresh out of school. Their VP of engineering is also straight out of school. From what they've said they're interested in someone who can help them improve both product and process but it sounds like I would be directly reporting to a couple kids with no experience. And they seem really interested in getting me on board.

    This isn't the only startup I've seen where everyone seems to be an officer of the company but it's got me wondering why. What is the point in giving everyone a fancy title? Someone like the CTO should know what he's doing and talking about. In short, he should have the experience and wisdom to make good decisions. Not only that but if all the important positions are already full that doesn't give new people much opportunity or incentive for advancement. Can someone shed some like on why they might be doing this? Does anyone have experience being the senior person at a company like this? How did it turn out?

    submitted by /u/1600ASA
    [link] [comments]

    Are there code translators?, something that takes code in one language and writes it in another

    Posted: 28 Aug 2018 07:11 AM PDT

    It would probably be very hard to make one, but it doesn't sound impossible to me, and it sounds so useful that I imagine someone might have made one already, or maybe I'm completely wrong and it is a dumb idea, I don't know, that's why I'm asking

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

    trouble with multiple pictures in slideshow slides

    Posted: 28 Aug 2018 10:28 AM PDT

    Hey! I'm someone who is learning how to code. I'm doing okay so far and I have been building my website, which hasn't given me any trouble yet. However, I want one feature in my website about which I can't find any solution anywhere. I have a slideshow for my illustration and 3D work, as you can see in the picture. The orange arrows are to go to the next work/project. The thing is that I really want to show more pictures of the same project in one slide. So, I put the pink arrows underneath, that way you can click on there and then it shows more pictures of the same work. So for example, the picture with the plant pot will show more pictures of the same work, when you click on the pink arrows (but from different angles). When you click on the orange arrows you go to the next work, the one with the glasses case.

    Some links to the pictures: https://78.media.tumblr.com/0af2755b403d1d53f76656f33f733843/tumblr_pe6kryQT7h1qenf7eo1_540.png

    https://78.media.tumblr.com/a45de51ef08a6cb1e2b18a60dd5cfa88/tumblr_pe6kryQT7h1qenf7eo2_540.png

    I hope im explaining it clearly haha. But I can't figure out how to do it! I also tried a version without the pink arrows, but instead numbers underneath (so a 1, 2, 3 and when you click on the 2 it goes to the next picture etc.). It seems like such a small and simple thing and yet there isn't a solution anywhere on the internet! I would really like to do it this way because my work looks the best presented like that...If someone wants to see my code so far, I have a google drive link I can share. can anyone help me? would mean loads to me!! :)

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

    How to keep users from reading text?

    Posted: 28 Aug 2018 08:42 AM PDT

    I'm making a dumb text adventure game in C# and am currently storing my text in .txt files. The average player can easily read these and spoil the game. I want to make it difficult for the average player to do this. Not neccessarily impossible (although impossible would be nice).

    What is the recommended solution to this? I'm currently thinking that I should include all the text (a lot of text) in a single class as strings so they are compiled as part of the executable. Bad idea?

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

    Good way of starting a small bussiness

    Posted: 28 Aug 2018 12:25 PM PDT

    or better said lower risk way...

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

    Is there a way to minify an entire web project? (HTML, CSS, JS, PHP)

    Posted: 28 Aug 2018 08:31 AM PDT

    Including in line JS and CSS displayed on the PHP files

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

    Learning Elixir, why do I need to use a tuple here?

    Posted: 28 Aug 2018 08:27 AM PDT

    I'm on the very first problem of hackerranks's Functional Programming track, taking two integers from STDIN and outputting their sum as STDOUT. This is what I thought would work:

    defmodule Solution do x = IO.gets "" y = IO.gets "" z = Integer.parse x a = Integer.parse y sum = z + a IO.puts sum end 

    However, I get (ArithmeticError) bad argument in arithmetic expression on line six, presumably because the previous two lines aren't working how I expect. I had a look at an example solution and they've done this:

    defmodule Solution do def input_values do a = IO.gets "" { a, _ } = Integer.parse a b = IO.gets "" { b, _ } = Integer.parse b sum = a + b IO.puts sum end end 

    I don't understand why it's necessary to use the { a, _ } and { b, _ } tuples instead of just assigning the value of Integer.parse to a new variable as I have done?

    submitted by /u/666lumberjack
    [link] [comments]

    Purposefully increasing cache miss rate (C++)

    Posted: 27 Aug 2018 10:50 PM PDT

    Using an application which measures memory bandwidth, I'm trying to increase the noise from DDR memory by running a C++ program which performs a large amount of write operations. My initial implementation used memset() calls, producing ~5000 MiB / s memory throughput. When using a spectrum analyzer while running this program, it produced a considerable amount of noise, but not as much as I had hoped for. My first intuition is that memset() writes to sequential memory locations, so after the first compulsory cache miss, subsequent writes (for as much as the cache line is capable of holding) just have to go to L1 cache instead of writing to main memory (assuming a write-back cache), so there is less traffic in the memory bus during this time.

    In an attempt to increase the noise output, I decided not to use memset() and instead do writes myself. Both programs use a 256 MB heap allocated buffer to write to, but for the program without memset(), I access randomized indices in the buffer so it's highly likely the memory location I want to write to isn't stored in any cache. The program writes whatever elements are stored in a uint64_t std::vector, representing the number of bytes I want to write to the 256 MB buffer. Assume that the amount of bytes I write are always < 256 MB. Below are the two programs:

    ​// with memset for (auto const &bytes : vec) { memset(buf\_256mb, 0, bytes); } 

    // without memset for (auto const &bytes : vec) { for (int i = 0; i < bytes; ++i) { buf_256mb[(rand() % MEM_BUF_SIZE_BYTES] = 0; } } 

    Using cachegrind, I verified that my program has double the rate of data cache misses in comparison to memset():

    // with memset() ==25149== ==25149== I refs: 3,234,499,037 ==25149== I1 misses: 2,974 ==25149== LLi misses: 2,144 ==25149== I1 miss rate: 0.00% ==25149== LLi miss rate: 0.00% ==25149== ==25149== D refs: 3,232,710,614 (747,560 rd + 3,231,963,054 wr) ==25149== D1 misses: 50,512,028 ( 15,110 rd + 50,496,918 wr) ==25149== LLd misses: 50,504,650 ( 8,559 rd + 50,496,091 wr) ==25149== D1 miss rate: 1.6% ( 2.0% + 1.6% ) ==25149== LLd miss rate: 1.6% ( 1.1% + 1.6% ) ==25149== ==25149== LL refs: 50,515,002 ( 18,084 rd + 50,496,918 wr) ==25149== LL misses: 50,506,794 ( 10,703 rd + 50,496,091 wr) ==25149== LL miss rate: 0.8% ( 0.0% + 1.6% ) 

    // without memset() ==10596== ==10596== I refs: 222,882,127,319 ==10596== I1 misses: 4,184 ==10596== LLi misses: 2,423 ==10596== I1 miss rate: 0.00% ==10596== LLi miss rate: 0.00% ==10596== ==10596== D refs: 93,718,777,343 (67,865,296,014 rd + 25,853,481,329 wr) ==10596== D1 misses: 3,231,469,279 ( 15,054 rd + 3,231,454,225 wr) ==10596== LLd misses: 3,181,160,608 ( 8,452 rd + 3,181,152,156 wr) ==10596== D1 miss rate: 3.4% ( 0.0% + 12.5% ) ==10596== LLd miss rate: 3.4% ( 0.0% + 12.3% ) ==10596== ==10596== LL refs: 3,231,473,463 ( 19,238 rd + 3,231,454,225 wr) ==10596== LL misses: 3,181,163,031 ( 10,875 rd + 3,181,152,156 wr) ==10596== LL miss rate: 1.0% ( 0.0% + 12.3% ) 

    Despite this, when running the program without memset(), the memory bandwidth analyzer displayed approximately 10 times slower memory throughput (~500 MiB/s). I have yet to run the application while using the spectrum analyzer, but I'd imagine the noise would be less since there's less memory throughput.

    My question is this: is there any more "de-optimization" of the cache I could do so I see more memory throughput? More importantly, how is it possible for a program with significantly more data cache write misses result in lesser memory throughput? If the CPU isn't writing to cache or main memory, where else could it be writing to?

    Here is a link to Cachegrind documentation, which describes what the different symbols mean. Thanks!

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

    Why does this work, but this doesn't? [Java Arrays]

    Posted: 28 Aug 2018 07:30 AM PDT

    This works:

    numOfRooms = input.nextInt(); int[] testArray = new int[numOfRooms]; 

    This doesn't

    numOfRooms = input.nextDouble(); double[] testArray = new double[numOfRooms]; 
    submitted by /u/twitch_imikey30
    [link] [comments]

    Using an Excel sheet to Update Values in an Database

    Posted: 28 Aug 2018 06:37 AM PDT

    Hi guys,

    I have an excel sheet with two columns: record IDs, and a new value to populate into a field for the record.

    I can connect to the target firebird database via IBExpert. I want to use IBExpert to "use" the spreadsheet to update the records.

    Does anyone know how to do that in IBExpert?

    Thanks!

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

    I have a question regarding the scope of Python multiprocessing

    Posted: 28 Aug 2018 06:29 AM PDT

    https://stackoverflow.com/questions/52054414/pool-map-doesnt-recognize-variable-declared-in-main-thread?noredirect=1#comment91059377_52054414

    Hi Guys, could you help me please?

    The question is how can I define a variable in the main thread, then share it throughout the threads generated by the pool.

    Any help would be appreciated.

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

    Do you guys think the programmers need their own code similar to doctors’ Hippocratic Oath?

    Posted: 28 Aug 2018 03:32 AM PDT

    We live in the age of technology and information. Programming basically penetrated every sphere of our life. Today we to the great extent depend on people who write the code. Programming is implicated in medicine, state security, road safety, and many other areas. Our lives depend on programmers. But some of them use their skills to be involved in drugs sells, distribution of child pornography, and human trafficking. So since programming is such an important part of our daily lives, do you think we need people who consider themselves programmers to follow some sort of the ethics code?

    If you agree, comment what rules you think a person in a profession should follow. This way we can compile a Programmer Code of Honor together.


    [link] [comments]

    No comments:

    Post a Comment