Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Post
  • Reply
feedmegin
Jul 30, 2008

Scaramouche posted:

+ Theoretically easier to get working on multiple platforms if that's important

He did specifically say Qt, which runs pretty much everywhere if he's doing Qt 5 - Android, iOS, MacOS, Linux, various commercial Unices, Windows, QNX, the lot.

Also, C++, verbose, when specifically compared to Java? Really?

Adbot
ADBOT LOVES YOU

Eikre
May 2, 2009
So let's say I wanna make it a little more difficult for my users to copy information from my application, and I'm worried about screenshots. I don't want to deactivate the prtscn button outright, but I want to blank out everything displayed in my program so that it's censored in an otherwise normal screenshot. I could just steal some AutoHotkey code and stand between the keyboard and OS, sniffing every keystroke so that I can hold the command, cover up, and pass it along, but that's kind of a back door I don't want to be responsible for (and I am required to not open it).

But I'm thinking that this might be a solved problem. Is there a way to request a heads-up from Windows that it's received a prtscrn keystroke before it actually executes a screenshot?


Please don't tell me that this is a fool's errand and that I'm never going to conquer dedicated idiocy or malice. I know.

Nemesis Of Moles
Jul 25, 2007

First off, thanks for the help with the script both of you, you're aces.

SurgicalOntologist posted:

Went a little overboard. The yield froms require python3. If you're on python3 replace "yield from <X>" with "for i in <X>: yield i". Untested.


edit; nvm, got it

nielsm
Jun 1, 2009



Eikre posted:

So let's say I wanna make it a little more difficult for my users to copy information from my application, and I'm worried about screenshots.

What if the user has a screenshotting application like Greenshot or something else that lets you take screenshots with a user-configurable key? Or using a screen recorder?
Those aren't exactly uncommon and I know that many office workers know of that kind of software.
Or even the Snipping Tool that comes with Windows.

No you can't really do anything about this. An old trick might have been using the "overlay" video mode, where your application window only shows a key color and the graphics card then fills that in with an image in a different framebuffer, outside what the OS can "see". That makes it very hard to screenshot, but overlay also isn't compatible with the DWM meaning you get Aero/desktop composition forcibly disabled. (And modern cards aren't really optimized for it, it's mostly a relic from when MPEG-2 decoder accelerator cards was a thing.)

muon
Sep 13, 2008

by Reene

ExcessBLarg! posted:

There's no licensing issue here if you're not distributing "your" code. The GPLv2 doesn't require that you release any derived work upon the world, just that you adhere to the license whenever you do distribute the derived work to another party.

There is a question though of ethics and plagarism though. It's one thing if the details of the process of context switching on a particular microcontroller are unintuitive due to the implementation of the controller itself. In that case, reading someone else's code as a form of documentation is generally considered OK, but the approach there is to actually write high level (possibly internal) documentation for the process, then to reimplement that in your own code. Ethically, it's appropraite to acknowledge the source of the documentation as being the other project, so you don't give the misimpression that the entire procedure is original.

The proper way to do a clean reverse engineer and reimplementation, which is important if you were to actually distribute the code as your own, is to have two different people involved. The first reads the other code and writes the spec document, while the other implements the new code from the spec document, but never looks at the original. That way, if this did ever come to trial, the person who wrote the code can honestly claim to have not read (and thus, couldn't have copied) the original, and the spec document itself clearly outlines the transfer of knowledge.
Thanks for that explanation. I think my code definitely qualifies as a modification of the original code, and I'll treat it as such.

Suspicious Dish
Sep 24, 2011

2020 is the year of linux on the desktop, bro
Fun Shoe

Eikre posted:

So let's say I wanna make it a little more difficult for my users to copy information from my application, and I'm worried about screenshots. I don't want to deactivate the prtscn button outright, but I want to blank out everything displayed in my program so that it's censored in an otherwise normal screenshot. I could just steal some AutoHotkey code and stand between the keyboard and OS, sniffing every keystroke so that I can hold the command, cover up, and pass it along, but that's kind of a back door I don't want to be responsible for (and I am required to not open it).

But I'm thinking that this might be a solved problem. Is there a way to request a heads-up from Windows that it's received a prtscrn keystroke before it actually executes a screenshot?


Please don't tell me that this is a fool's errand and that I'm never going to conquer dedicated idiocy or malice. I know.

I'll just take a pic of it with my smartphone tbh

Eikre
May 2, 2009

nielsm posted:

What if the user has a screenshotting application like Greenshot or something else that lets you take screenshots with a user-configurable key? Or using a screen recorder?

Then somebody else hosed up in a really obvious and implicating way.

But there really isn't anything I can do about that. But if I do the prtscrn thing, then someone will think that it's neat. That's really the extent of the utility, if we're being honest about it.

Suspicious Dish
Sep 24, 2011

2020 is the year of linux on the desktop, bro
Fun Shoe

nielsm posted:

No you can't really do anything about this. An old trick might have been using the "overlay" video mode, where your application window only shows a key color and the graphics card then fills that in with an image in a different framebuffer, outside what the OS can "see". That makes it very hard to screenshot, but overlay also isn't compatible with the DWM meaning you get Aero/desktop composition forcibly disabled. (And modern cards aren't really optimized for it, it's mostly a relic from when MPEG-2 decoder accelerator cards was a thing.)

Video overlays are still a thing. Today, the way it's done is that the HW plane is blended under the RGB layer, and the OS does a carveout and zeroes out the alpha channel for the region where the video is going to be.

This has all the benefits of video overlays and chroma keys combined, plus you get full alpha blending for elements on top of the video (subtitles, media control).

Hughmoris
Apr 21, 2007
Let's go to the abyss!
What is a very simple database a non-programmer should look at using for a small project?

I am looking at tackling a problem at work, as a side project. The hospital I am working at does not have a way to track how long beds are dirty, after a patient is discharged. I was thinking of writing a very simple program with 3 steps in the workflow:

1. User logs in with a badge number (no password needed, the badge number just helps further analytics)
2. Next screen shows a list of beds. User clicks on a bed.
3. Next screen shows two buttons. "Started Cleaning Room" and "Room is Now Clean"
repeat....

The scenario is a patient is discharged from room 320. John comes to the computer, logs in, selects room and clicks the "Started Cleaning Room" button. After he finishes cleaning the room he goes to the computer, logs in, selects room and clicks "Room is Now Clean".

I was thinking a simple database would be helpful as I could capture the data and do simple reports such as an average of how long a room stays dirty, average time a specific worker takes to clean a room etc...

I am looking at learning enough C# to write the GUI. Any advice for this project?


*I should rephrase this. Our EMR captures the data in some format but there is no one at the moment that can do anything with it, and I don't have access to the raw data.

Hughmoris fucked around with this message at 04:19 on Jan 9, 2015

JawnV6
Jul 4, 2004

So hot ...
Go talk to operations so they can tell you their personnel won't be trained on your system nor want to take the time to use it in production now before you spend all that effort?

Figure out some automated way to detect when cleaning might be happening with hardware and rely on that instead. Like, are the lights in the room off between discharge and cleaning? Hook up an ambient light sensor and track that instead. People never want to learn or do anything and assuming you get buyin human error in the input will make it worthless anyway.

The MUMPSorceress
Jan 6, 2012


^SHTPSTS

Gary’s Answer

Hughmoris posted:

What is a very simple database a non-programmer should look at using for a small project?

I am looking at tackling a problem at work, as a side project. The hospital I am working at does not have a way to track how long beds are dirty, after a patient is discharged. I was thinking of writing a very simple program with 3 steps in the workflow:

1. User logs in with a badge number (no password needed, the badge number just helps further analytics)
2. Next screen shows a list of beds. User clicks on a bed.
3. Next screen shows two buttons. "Started Cleaning Room" and "Room is Now Clean"
repeat....

The scenario is a patient is discharged from room 320. John comes to the computer, logs in, selects room and clicks the "Started Cleaning Room" button. After he finishes cleaning the room he goes to the computer, logs in, selects room and clicks "Room is Now Clean".

I was thinking a simple database would be helpful as I could capture the data and do simple reports such as an average of how long a room stays dirty, average time a specific worker takes to clean a room etc...

I am looking at learning enough C# to write the GUI. Any advice for this project?

Does your hospital have an EMR? Any non-lovely EMR system has an environmental services module that does this. If you have a lovely EMR then your hospital is passing on tasty government incentive cash and you should probably escalate that.

Hughmoris
Apr 21, 2007
Let's go to the abyss!

JawnV6 posted:

Go talk to operations so they can tell you their personnel won't be trained on your system nor want to take the time to use it in production now before you spend all that effort?

Figure out some automated way to detect when cleaning might be happening with hardware and rely on that instead. Like, are the lights in the room off between discharge and cleaning? Hook up an ambient light sensor and track that instead. People never want to learn or do anything and assuming you get buyin human error in the input will make it worthless anyway.

:smith:

I was thinking about trying my hand at this for two reasons. One, simply as a project to learn a little bit about GUIs and databases. Two, I had to tell this nice manager today that even though all of this data is already collected by our EMR, we don't have a BOXI guy that can write the report he needs. I've pleaded with the higher-ups to let me learn BOXI but its fallen on deaf ears. So, I thought my solution would be a hacked together workaround.

LeftistMuslimObama posted:

Does your hospital have an EMR? Any non-lovely EMR system has an environmental services module that does this. If you have a lovely EMR then your hospital is passing on tasty government incentive cash and you should probably escalate that.

Oh, we definitely have an EMR that captures the data but we don't have anyone that has the time or know-how to sift through it and for some reason they refuse me access to learn it.

The MUMPSorceress
Jan 6, 2012


^SHTPSTS

Gary’s Answer

Hughmoris posted:

:smith:

I was thinking about trying my hand at this for two reasons. One, simply as a project to learn a little bit about GUIs and databases. Two, I had to tell this nice manager today that even though all of this data is already collected by our EMR, we don't have a BOXI guy that can write the report he needs. I've pleaded with the higher-ups to let me learn BOXI but its fallen on deaf ears. So, I thought my solution would be a hacked together workaround.


Oh, we definitely have an EMR that captures the data but we don't have anyone that has the time or know-how to sift through it and for some reason they refuse me access to learn it.

I'm sorry, that's messed up on multiple levels. It also disturbs me that your EMR captures the data but doesn't provide a way to make it actionable. That's basic stuff. I'm biased as I work for an EMR vendor, but env services is one of those things that we don't even let customers say no to buying because cleaning beds and getting them filled efficiently saves a surprising number of lives.

Googling BOXI is leading me to a lot of unrelated results. Can you tell me who the vendor is? Maybe I can dig you up some documentation on that. If you're going to hack something together, at least do it in the format your EMR uses natively so that your actual IT people have some motivation to take it and fix it up later.

Hughmoris
Apr 21, 2007
Let's go to the abyss!

LeftistMuslimObama posted:

I'm sorry, that's messed up on multiple levels. It also disturbs me that your EMR captures the data but doesn't provide a way to make it actionable. That's basic stuff. I'm biased as I work for an EMR vendor, but env services is one of those things that we don't even let customers say no to buying because cleaning beds and getting them filled efficiently saves a surprising number of lives.

Googling BOXI is leading me to a lot of unrelated results. Can you tell me who the vendor is? Maybe I can dig you up some documentation on that. If you're going to hack something together, at least do it in the format your EMR uses natively so that your actual IT people have some motivation to take it and fix it up later.

I have a rough understanding of it but BOXI is Business Objects XI software that is used to write reports off our EMR data. Our BOXI writer is just inundated with projects he is working on for other departments, so I thought I'd try my hand at a solution.

I'm mainly just bouncing ideas around but JawnV6 is probably right. The last thing people want to deal with is learning yet another program to do their job.

Hughmoris fucked around with this message at 04:53 on Jan 9, 2015

The MUMPSorceress
Jan 6, 2012


^SHTPSTS

Gary’s Answer

Hughmoris posted:

I have a rough understanding of it but BOXI is Business Objects XI software that is used to write reports off our EMR data. Our BOXI writer is just inundated with projects he is working on for other departments, so I thought I'd try my hand at a solution.

I'm mainly just bouncing ideas around but JawnV6 is probably right. The last thing people want to deal with is learning yet another program to do their job.

Oh, I've never heard Busines Objects abbreviated with the version number in it like that before. I assume you guys have Crystal Reports then?

I agree that this is something your IT/EMR vendor should be doing, but for what it's worth you can probably write a SQL query to populate a really rudimentary crystal report if your bed data is in a remotely sane format in your database.

However, having had to bail out orgs who were struggling due to understaffing, you should definitely escalate it to management that your reporting person doesn't have time for this. Env services is crazy important for infection prevention and control (I'm sure you know that), and if his time is that scarce they should be hiring for another report writer yesterday.

Hughmoris
Apr 21, 2007
Let's go to the abyss!

LeftistMuslimObama posted:

Oh, I've never heard Busines Objects abbreviated with the version number in it like that before. I assume you guys have Crystal Reports then?

I agree that this is something your IT/EMR vendor should be doing, but for what it's worth you can probably write a SQL query to populate a really rudimentary crystal report if your bed data is in a remotely sane format in your database.

However, having had to bail out orgs who were struggling due to understaffing, you should definitely escalate it to management that your reporting person doesn't have time for this. Env services is crazy important for infection prevention and control (I'm sure you know that), and if his time is that scarce they should be hiring for another report writer yesterday.

I don't want to clog up the thread but if you're up to talking about this subject a little more, can you PM me or shoot me an email at sylints at gmail dot com?

The MUMPSorceress
Jan 6, 2012


^SHTPSTS

Gary’s Answer

Hughmoris posted:

I don't want to clog up the thread but if you're up to talking about this subject a little more, can you PM me or shoot me an email at sylints at gmail dot com?

Sent you an email.

Munkeymon
Aug 14, 2003

Motherfucker's got an
armor-piercing crowbar! Rigoddamndicu𝜆ous.



LeftistMuslimObama posted:

However, having had to bail out orgs who were struggling due to understaffing, you should definitely escalate it to management that your reporting person doesn't have time for this. Env services is crazy important for infection prevention and control (I'm sure you know that), and if his time is that scarce they should be hiring for another report writer yesterday.

This guy got roped into trying to automate UI testing a few months ago IIRC, so I'm thinking his management is not into spending money on hiring IT people.

JawnV6
Jul 4, 2004

So hot ...

Hughmoris posted:

I'm mainly just bouncing ideas around but JawnV6 is probably right. The last thing people want to deal with is learning yet another program to do their job.
I don't enjoy being right about it, as I so often do with other things I'm right about, but with systems design the human is the point of failure. Won't learn, won't do it right after they've learned, won't tell you when they screwed up so that any sane process could fix it up afterwards. I've been in planning meetings where ops was represented and forcefully pushed back on anything that required another hire.

If you already have the data in some form, and it sounds like you do, that's the best way to extract what you need. Otherwise, I was totally serious about the light tracking, if lights go off at discharge and on at cleaning, it's a very simple hardware setup to detect and log that information. Won't be perfect (i.e. sunlight tripping it) but it would get you closer to the real data you're after with less buyin and less work.

Hughmoris
Apr 21, 2007
Let's go to the abyss!

Munkeymon posted:

This guy got roped into trying to automate UI testing a few months ago IIRC, so I'm thinking his management is not into spending money on hiring IT people.

Yep, that was me. That situation was an absolute cluster but with a ton of help from people in the CoC and my trusty friend Google, I managed to hack together something that met the goal and I came out of it looking like a Rock Star (I'm not) to the non-technical corporate honchos.

JawnV6 posted:

I don't enjoy being right about it, as I so often do with other things I'm right about, but with systems design the human is the point of failure. Won't learn, won't do it right after they've learned, won't tell you when they screwed up so that any sane process could fix it up afterwards. I've been in planning meetings where ops was represented and forcefully pushed back on anything that required another hire.

If you already have the data in some form, and it sounds like you do, that's the best way to extract what you need. Otherwise, I was totally serious about the light tracking, if lights go off at discharge and on at cleaning, it's a very simple hardware setup to detect and log that information. Won't be perfect (i.e. sunlight tripping it) but it would get you closer to the real data you're after with less buyin and less work.

After reading your response last night about monitoring the lights, I started brainstorming a more passive approach to meet the goal. The goal being capturing how long it takes the janitorial services to clean a room once its been marked "Dirty". Now, the ER uses a visual application called a trackerboard to monitor their department's bed flow. The trackerboard is always displayed on a central monitor and has all of the rooms listed. When a room is dirty, it turns BLUE on the trackerboard. When the room is clean or occupied, it turns a non-blue color.

So, I've whipped up something with AutoIt using their PixelGetColor function. The basics of my program is that it will watch what is being displayed, and if it detects a BLUE pixel at specific locations, it will know a room has become dirty and it will send that room number and time stamp to a textfile, and remember the state of that room. When that bed is cleaned and that pixel location turns non-blue, the program will know the room has been cleaned and it will send that info to the text file as well.

I'm probably not explaining it well but I've tested it as a proof of concept, monitoring 2 beds in the training environment, and it works. Now I just need to build it to monitor all the beds on the trackerboard. Also, there has to be a better way to save the data than to a tab delimited text file. Or is that an acceptable way, and I should just open the file and work with the data in Excel?

Also, I need to plan out failure points for this script. For instance, it would fail if someone minimized the trackerboard window, or if the central monitor turned off etc...

I know this definitely comes off as amateur hour but its a fun problem to try and tackle.

Dominoes
Sep 20, 2007

Hey, so from last page, went with C++. So far, feels like Python with brackets, semicolons and variable declaration. Or just like javascript.

Suspicious Dish
Sep 24, 2011

2020 is the year of linux on the desktop, bro
Fun Shoe
You're in for a disappointing shock sometime soon, I guess.

Dominoes
Sep 20, 2007

That happened with Haskell. Although that was partly due to the tutorial I was using having you memorize (memoize? :rimshot:) every function in the standard library.

Dominoes fucked around with this message at 10:45 on Jan 10, 2015

Lord Windy
Mar 26, 2010
I've been making Interactive Fiction games in my spare time and one of the big issues with the genre is it is not very user accessible. Most games require you to download an interpreter and the file itself, which is fine for people who enjoy IF but it's not easy for people to get started (particularly not tech savvy people). I want to make something that is user accessible and doesn't require the user to download anything. My original idea of using Telnet is really not much more user friendly than what we have now, so I'm investigating some browser based solutions.

I've never done any real webpage stuff, I mean I've done some PHP, HTML and CSS hello world poo poo but that would be about it. So I have no idea on how to tackle this. What sort of technology should I be looking at? Trying to make a telnet client with Javascript seems the easiest option (and probably one that has a heap of Open Source material, if not a complete implementation I can use and just get back to doing IF) but if I wanted to make a full on browser based IF using HTML Canvas and Javascript to capture key presses and send stuff to the server (I know I could make this entirely browser based, but I want to keep the actual game on the server itself. Dissuade me if this is a really bad idea) what should I look at? The only technology I know of are CGI for C/Java and PHP.

mystes
May 31, 2006

Lord Windy posted:

I've been making Interactive Fiction games in my spare time and one of the big issues with the genre is it is not very user accessible. Most games require you to download an interpreter and the file itself, which is fine for people who enjoy IF but it's not easy for people to get started (particularly not tech savvy people). I want to make something that is user accessible and doesn't require the user to download anything. My original idea of using Telnet is really not much more user friendly than what we have now, so I'm investigating some browser based solutions.

I've never done any real webpage stuff, I mean I've done some PHP, HTML and CSS hello world poo poo but that would be about it. So I have no idea on how to tackle this. What sort of technology should I be looking at? Trying to make a telnet client with Javascript seems the easiest option (and probably one that has a heap of Open Source material, if not a complete implementation I can use and just get back to doing IF) but if I wanted to make a full on browser based IF using HTML Canvas and Javascript to capture key presses and send stuff to the server (I know I could make this entirely browser based, but I want to keep the actual game on the server itself. Dissuade me if this is a really bad idea) what should I look at? The only technology I know of are CGI for C/Java and PHP.
Why telnet why a canvas element why why why? The entire point of a web browser is to talk to servers and display text :(.

lunar detritus
May 6, 2009


mystes posted:

Why telnet why a canvas element why why why? The entire point of a web browser is to talk to servers and display text :(.

Basically this.

Anyway, most popular IF languages have web based interpreters (Inform 7, zmachine).

Dren
Jan 5, 2001

Pillbug

Suspicious Dish posted:

You're in for a disappointing shock sometime soon, I guess.

Was that aimed at Dominoes, HughMorris, or both?

ArcticZombie
Sep 15, 2010
EDIT: I thought of an alternative way to add the functionality I wanted which makes this unnecessary.

I'm creating a Scrabble solver, storing the word list in a DAWG (Directed Acyclic Word Graph). I created a DAWG from a word list using a python wrapper of dawgdic. In order to now read and use the DAWG I created, I'm using a pure python module, DAWG-Python.

Now, I have to modify DAWG-Python to add some functionality for use in the Scrabble solver. In order to do that I need to better understand what's going on internally to traverse the DAWG. I can't figure out the format the DAWG is stored in. In the example on this page each node is stored as 4 bytes, the first 2 bytes are pointers to the child node, 3rd byte is any flags and the 4th byte is the character. In the DAWG created by dawgdic it is not the same:



I can tell that the first byte stores the character, but I'm not so sure about the other bytes. Judging by how the 4th byte doesn't have a lot of variation, I think that the 2nd and 3rd bytes store a pointer of some kind and the 4th byte stores the flags. It doesn't seem to make sense though. At offset 44 of the image above is the node containing the first "J" node. The bottom of the image below shows the node containing "O", following "J".



Here is the code from the module which seems to handle following these pointers:

Python code:
def follow_char(self, label, index):
    "Follows a transition"
    offset = units.offset(self._units[index])
    next_index = (index ^ offset ^ label) & units.PRECISION_MASK

    if units.label(self._units[next_index]) != label:
        return None

    return next_index
And some code from the units module it uses:

Python code:
# -*- coding: utf-8 -*-
"""
Unit of a dictionary
"""
from __future__ import absolute_import

PRECISION_MASK = 0xFFFFFFFF

OFFSET_MAX = 1 << 21
IS_LEAF_BIT = 1 << 31
HAS_LEAF_BIT = 1 << 8
EXTENSION_BIT = 1 << 9

def has_leaf(base):
    " Checks if a unit has a leaf as a child or not."
    return bool(base & HAS_LEAF_BIT)

def value(base):
    "Checks if a unit corresponds to a leaf or not."
    return base & ~IS_LEAF_BIT & PRECISION_MASK

def label(base):
    "Reads a label with a leaf flag from a non-leaf unit."
    return base & (IS_LEAF_BIT | 0xFF)

def offset(base):
    "Reads an offset to child units from a non-leaf unit."
    return ((base >> 10) << ((base & EXTENSION_BIT) >> 6)) & PRECISION_MASK
I cannot work out how it is getting from that "J" node to anywhere near the "O" node, I can't make sense of the bitwise operations going on here to figure out what's happening. Can anyone explain it to an idiot?

ArcticZombie fucked around with this message at 19:48 on Jan 10, 2015

Suspicious Dish
Sep 24, 2011

2020 is the year of linux on the desktop, bro
Fun Shoe

Dren posted:

Was that aimed at Dominoes, HughMorris, or both?

I'm like a high school English teacher. There are many layers to my posting, and the correct interpretation is up to you.

yippee cahier
Mar 28, 2005

First of all, you have an array of 32-bit little endian values. Switch your hex display to LE to make it make a little more sense.

ufarn
May 30, 2009
If I'm a Python/Django guy who wants to play around with another web-centred programming language that runs better than a Ruby/Python framework, Go would be the most obvious choice, right?

Hearing some things about Rust, but dunno, but Go gets the most mentions.

KernelSlanders
May 27, 2013

Rogue operating systems on occasion spread lies and rumors about me.
I have an algorithm problem that seems like the kind of thing that probably already has a name and a bunch of literature on implementation methods (and is probably NP-hard), but I can't seem to find what it is.

Given a list L of items and their associated costs, e.g., ((A, 1), (B, 2), (C, 1.5)), and a set S of sets of items: e.g. ((A, B), (A), (A, C)), find the subset l of L that maximizes the number of sets in S who's items are all contained in l subject to some constraint on the total cost of items in l.

It seems like it's probably related to portfolio optimization or the knapsack problem in some way, but I'm not seeing the precise mapping. Any ideas?

KernelSlanders
May 27, 2013

Rogue operating systems on occasion spread lies and rumors about me.

ufarn posted:

If I'm a Python/Django guy who wants to play around with another web-centred programming language that runs better than a Ruby/Python framework, Go would be the most obvious choice, right?

Hearing some things about Rust, but dunno, but Go gets the most mentions.

Go or Scala/Play. Rust is still very much an alpha stage language.

Blinkz0rz
May 27, 2001

MY CONTEMPT FOR MY OWN EMPLOYEES IS ONLY MATCHED BY MY LOVE FOR TOM BRADY'S SWEATY MAGA BALLS

ufarn posted:

If I'm a Python/Django guy who wants to play around with another web-centred programming language that runs better than a Ruby/Python framework, Go would be the most obvious choice, right?

Hearing some things about Rust, but dunno, but Go gets the most mentions.

C#

ultrafilter
Aug 23, 2007

It's okay if you have any questions.


KernelSlanders posted:

I have an algorithm problem that seems like the kind of thing that probably already has a name and a bunch of literature on implementation methods (and is probably NP-hard), but I can't seem to find what it is.

Given a list L of items and their associated costs, e.g., ((A, 1), (B, 2), (C, 1.5)), and a set S of sets of items: e.g. ((A, B), (A), (A, C)), find the subset l of L that maximizes the number of sets in S who's items are all contained in l subject to some constraint on the total cost of items in l.

It seems like it's probably related to portfolio optimization or the knapsack problem in some way, but I'm not seeing the precise mapping. Any ideas?

You can formulate this as a 0-1 integer program and use standard solvers to get the answer.

Linear Zoetrope
Nov 28, 2011

A hero must cook

KernelSlanders posted:

Go or Scala/Play. Rust is still very much an alpha stage language.

Rust is releasing its 1.0 within the next few weeks/months, no?

Gul Banana
Nov 28, 2003

yes, but i wouldn't call it web-centered. it's a system programming language, competing with c++ more than anything.

seconding the suggestions of C# and Scala as being good for web backends

midnightclimax
Dec 3, 2011

by XyloJW
If you're a complete newb, is there something like a "natural progression" in terms of what languages you're supposed to learn? I'm interested in LISP, and that edx course I'm taking (Harvard CS50) starts with C, so those are the two I'm focussing on right now. Just wondering if there's anything else I should dip my toes in/be aware of.

KernelSlanders
May 27, 2013

Rogue operating systems on occasion spread lies and rumors about me.

Jsor posted:

Rust is releasing its 1.0 within the next few weeks/months, no?

That's the plan. 1.0 Alpha was their last release and the recommend using nightly builds, but I wouldn't develop a production app with it for a while yet.

Adbot
ADBOT LOVES YOU

raminasi
Jan 25, 2005

a last drink with no ice

midnightclimax posted:

If you're a complete newb, is there something like a "natural progression" in terms of what languages you're supposed to learn? I'm interested in LISP, and that edx course I'm taking (Harvard CS50) starts with C, so those are the two I'm focussing on right now. Just wondering if there's anything else I should dip my toes in/be aware of.

You should try to get a good survey of "genres" with your first few languages, but there's not really a canonical order. If you're interested in Lisp you might want to check out Scheme (because it's simple and has been used as a good teaching language for awhile) or Clojure (because it's a JVM language) before Common Lisp.

  • 1
  • 2
  • 3
  • 4
  • 5
  • Post
  • Reply