Losing train of thought Ask Programming |
- Losing train of thought
- Need some Vdos Plus assistance
- Stacking two images together in Python?
- [JS] If a lot of function parameters are bad, what should I do then if I need a lot of parameters in my function? And how do I pass top parameters into function functions without redundance and naming them the same way?
- Redirection of URLs on a VPN
- [C] What am I doing wrong? String comparison
- [HTML CSS JS] What is the standard procedure if you want to remove a flex element with lots of children?
- Issues with C program?
- How to calculate this formula
- [HTML, Javascript, PHP] Targeting iframes results in opening a new tab instead
- Can anyone help with workflow for programming on VPS?
- Are there any languages that support the idea of strict, type-safe, domain-specific primitives?
- After my first 40 hour week I am absolutely exhausted and I mess up the most little things. I feel that there is some vitamin Im missing.
- Trying to make g-code posting allow # as a legal character.
- JSON polyline points parser
- [ASP.NET] Why is my session item returning null every time?
- Different ids in production
- Can tasks on your mobile device be automated with your own programming?
- I'm not sure if this the right place to ask this but here I go
- Sorting Algorithm
- How do I convert a very large base36 number into base10 using Python?
- how to write junit tests for payment gateways (Stripe, Paypal)
- Making Something Like Archillect
- Need help understanding microservices components
- Mongo: Create a complex query with a hasMany relationship
Posted: 18 Feb 2020 01:01 PM PST I'm a game developer with abt 5 years of experience and a considerable coding background. On paper I'm a middle/senior Dev who abides by the patterns and principles of programming and architecture. For abt a year though I've had this persistent issue - I hit a mental brick wall when solving any task even slightly above trivial. Whenever I try to visualize an issue and take a certain amount of variables into consideration, I hit a mental brick wall. My train of thought just falls apart. It's like a thick mist, and I can only see a few feet ahead. I get there eventually through trial and error, piece by piece. Having to piece together small parts of a problem though means a lot of overhead. I'm terribly slow and ineffective, and it shows. I got fired from my last job for that exact reason. Has this happened to anyone else? Did I just go full stupid overnight? How do I get that clarity of thought back? [link] [comments] |
Need some Vdos Plus assistance Posted: 18 Feb 2020 09:20 PM PST I posted in my city's sub to help me tackle this and not so much a peep. Been trying to figure out the Vdos Plus setup. There's not much documentation on it. Maybe I'm over thinking this. I have extracted the data from the hard drive. And placed it in the correct (the root of Vdos plus folder, exactly how the previous owner had it setup. And I can't get it to run correct Had to purchase another tower, because i found that I needed windows 7 to make it work. That cleared all the errors I was facing. But it's still not running. Now I know that I'm missing something simple. And I can't think of what. Any help will be great. Thank You for reading. [link] [comments] |
Stacking two images together in Python? Posted: 18 Feb 2020 07:47 PM PST Hi, I was wondering if anyone knew of a way to stack two images together into one in python? I don't mean one on top of another in OpenCV windows. I mean literally taking a (256,256) and another (256,256) image and creating a (256,256,2) or (256,256,6) (if color) image. Basically: I need to stack two images to pass them into a Keras neural network but the original way the user whose picture I'm using did it was through tfrecords that don't seem to work with Keras. So I need to find a new method. Unfortunately, it's really hard to search for this since less arcane definitions of "stacking" or "combining" predominate. Thank you [link] [comments] |
Posted: 18 Feb 2020 07:33 AM PST problem: As you see, we have a lot of parameters, some of which may appear in two or more sub-functions. And we also have a parameter-less container sub-function which needs to access the top function's parameter but can't. So,
Recently, whenever I come to a part that has something to do with GUI, I'm immediately: "oof, ouch, owie, my bones hurt". Making sub-functions is hard because of scope and repetitiveness. I'm with one foot out of the door on this project and html desktop apps in general. I feel like I should switch to python, but I just love javascript because I have been coding in gamemaker (quasi-javascript synthax) for quite some time before even learning the web technologies. Tnx! [link] [comments] |
Posted: 18 Feb 2020 06:51 PM PST I want to make some friends connect through a vpn, and I want to make some pages redirect to other pages. The vpn is based on wireguard(Ubuntu 16.0.4) and I'm open to using other kinds of software since we're hosting this on Digital Ocean. EG Peter gets into youtube.com while connected, gets redirected to google.com [link] [comments] |
[C] What am I doing wrong? String comparison Posted: 18 Feb 2020 12:38 PM PST An exercise from a book: Write a function that deletes each character in s1 that matches any character in the string s2. The code: I input characters of S1 and S2, but there isn't a valid result. Just a random char. Like: S1: linux S2: unix Result: V&z [link] [comments] |
Posted: 18 Feb 2020 12:23 PM PST I made a little example for you: https://www.w3schools.com/code/tryit.asp?filename=GC280J6AJS99 EDIT: I just realized none of my elements have actual children. Here is a link which adds an empty child to each element: https://www.w3schools.com/code/tryit.asp?filename=GC28PP7E2BCF So, I am creating a random number of elements which are objects themselves. I should be able to add and remove elements as I want. But adding is easy, and removing is not. You either get an element floating in space, or orphans. The problem arises when we want to delete an element in the middle of the set of elements.
Furthermore, I have no connection between the elements and the data. We remove the visual element (actually I only hide it in my example to show how it should look), but we don't delete the data. The logical way would be to connect them via indexes, but that's not enough. That's not secure. We need a proper connection where we know exactly which data belongs to which visual element, and which element belongs to each data.
The object bracket notation comes to mind. Then we would just push a string with our delete function, and that string would give us the correct property of the object. But how would we loop through it then if we don't have indexes? Really hard thing to consider. For me at least. But I'm sure you already know the optimal solution. Please advise! [link] [comments] |
Posted: 18 Feb 2020 06:14 PM PST Not sure if this is the most appreciate place but a professor of mine gave us this code to run but when I attempt to run it I get "./Lab5Q1.c: line 2: syntax error near unexpected token `('./Lab5Q1.c: line 2: `int main()'" Really would appreciate if someone could help me figure out whats going on. I don't get the issue with int main()... #include<stdio.h> int main() { int a[10], *p, *q; p = &a[2]; q = p +1; q = q + 1; *q = 123; p = q; printf("%d\n", *p); printf("%d\n", a[4]); } [link] [comments] |
Posted: 18 Feb 2020 06:10 PM PST The formula is " The formula for the roll from the id is roll = (((id >> 8) & 0xFFFF) % 0x86A1) + (id & 0xFFFF) ". The id in my case is 410000C9. [link] [comments] |
[HTML, Javascript, PHP] Targeting iframes results in opening a new tab instead Posted: 18 Feb 2020 06:02 PM PST Hi there, need some help on this. So I have page1.php on server1 and page2.php on server2. On server1, I have a main.php page that has two iframes, iframe1 and iframe2 where each points to page1.php and page2.php respectively. In page2.php, I have a function that would automatically trigger the function window.open('https://example.com', 'iframe1') whenever an event is going on. However, whenever the function is triggered, instead of the iframe1 being targeted, a new tab is opened instead, I have tried looking into the console logs but I cannot find anything that would explain the behaviour. Any help on this? Edit1: I am guessing this has something to do with different hostnames that results in this behaviour, will look into it more [link] [comments] |
Can anyone help with workflow for programming on VPS? Posted: 18 Feb 2020 05:20 PM PST Hey all, Not sure if this post belongs here but I'm not sure where else to ask, let me know if I should go elsewhere. I'm using a VPS on digital ocean to do homework for my compilers class and I'm trying to find a better workflow. The crux of the issue is that we're assembling 32 bit binaries wich is no longer supported on macOS Catalina (without some work arounds that our graders/instructor would rather us not do) so working locally isn't an option for me. We're creating our compilers in Haskell using Haskell Stack. I've been using an ubuntu droplet on digital ocean but the workflow is starting to get annoying and I'm wondering if anyone here can help me find something better. This is what I'm currently doing:
The main problem I'm having is that my ssh connection drops if I'm not constantly interacting with it. I'm not sure if this is a normal ssh thing or if its because I'm using ssh and sshfs simultaneously because I've never had a problem maintaining ssh sessions before this. Also sometimes sshfs is slow and editor starts to stutter or files don't update right away. Is there a better way to do this? I've considered just working in vim through ssh, but I'm much more efficient in Atom. Maybe I just need to put more effort in to learning some more advanced VIM techniques. I'm open to suggestions. I'd also be interested in finding a way to make this more automated, like if I could just save my code and have the droplet see that things have changed and then rebuild and run the testing suite. Or if there was a way to work locally (and not deal with sshfs at all) and then push my changes to the VPS (instead of right to GitHub) and have it automatically build and run that would be cool. Sorry If this is too open ended, Im just really used to working locally and using a fairly simple toolset, so I don't really know how to make this better. I'm open to any suggestions (that don't cost money) Thanks for any input! [link] [comments] |
Are there any languages that support the idea of strict, type-safe, domain-specific primitives? Posted: 18 Feb 2020 10:57 AM PST In writing code that interacts with a database, it's almost inevitable that you're going to be holding onto abstract keys (big integers or GUIDs), and a given schema may have dozens or hundreds of different domains (e.g. CustomerId, ProductId, AccountId, etc.). Of course, passing a CustomerId into a function that wants an AccountId is just about the worst kind of type mismatch you would ever have the misfortune to debug, yet, as far as I know, no major language supports something like: such that you'll get a compiler/build-time error. Sure, you can create a templated class (in C++) that would hold onto this and provide a number of utility functions that would give it the same behavior as a int (or string, or whatever you want as your underlying implementation), but it feels like a feature that is needed often enough that it should be built in. [link] [comments] |
Posted: 18 Feb 2020 12:38 AM PST I know that caffeine+theanine doesnt help anymore, it does speed me up but I still can't grasp a lot of things in my head right now like Im not of fuel. I know that after a month or so I will feel on the top of my game again but after a week I'll be exhausted again. Is there some essential vitamin for that much of a brain work? Im not sure if it's sugar or vitamin B or omega-3 or choline that Im lacking or anything else. [link] [comments] |
Trying to make g-code posting allow # as a legal character. Posted: 18 Feb 2020 10:45 AM PST Total amateur in coding, but I'll try to make this fairly understandable even without knowledge of the requisite programs. I am a CNC programmer trying to make Autodesk Fusion 360 post processor output g-code where the length and diameter offsets are posted as H#3020 and D#3020 respectively. Fusion post processing works by following a configuration .txt file using (I believe) Java coding. The machine using the posted file uses the aforementioned H# and D# codes which can be edited after the program is posted, but that's annoying, so I want to make it easier. I have made edits to the configuring files before, and even the H and D posting, but using # caused the post to fail showing the following
I can provide further details if asked, but my primary desire is to make the post treat # as though it were a number/letter. please and thanks. [link] [comments] |
Posted: 18 Feb 2020 03:41 PM PST I want to parse the entire JSON file that contains many JSONObjects "steps". I need to extract all polylines and their points. However, it returns only the very first value and nothing more. Is anything wrong with my loop or I just parse the JSON file wrongly? Thx https://gist.github.com/Biseamon/64515eefec707a9c3cb4fcc38dec56a1 [link] [comments] |
[ASP.NET] Why is my session item returning null every time? Posted: 18 Feb 2020 09:30 AM PST So I'm working on a basic kind of log-in system (I'm a beginner), and I cannot, for the life of me, set a value to one of my session state items. It just doesn't want to take. This is what I have in the login event handler: Then, in separate form, I have this in my page load: I don't know why the "Admin" session item isn't working... any help would be much appreciated. [link] [comments] |
Posted: 18 Feb 2020 11:06 AM PST We have an app at work in which there can be created multiple roles for users to have certain permissions. Recently, I implemented a functionality for a new role, and to verify if the current user has that role, I check if the user has associated the id of the newly created role in the MYSQL table with roles and users. For that, I created a constant with the new role; in development environment everything worked fine, but in production, the id of the new role didn't coincide, as they already had created a different role before that took that id. How should this have been done to avoid the problem with different ids? [link] [comments] |
Can tasks on your mobile device be automated with your own programming? Posted: 18 Feb 2020 06:15 AM PST Rookie programmer here, Wanted to know if it would be possible to create a bot that can scrape various apps or online data right on my phone. Thanks for any input! [link] [comments] |
I'm not sure if this the right place to ask this but here I go Posted: 18 Feb 2020 01:26 PM PST So hi I'm an aspiring coder who wants to work on like high level things like operating systems and the like or even just like useful and good software but like I don't know why today I'm just feeling like what's the point I'll never be good and like it's not even creative to do this. So my question is like is programming actually creative and like are those things I want to do good fields to go into to be creative? [link] [comments] |
Posted: 18 Feb 2020 01:06 PM PST I'm trying to write a comparator function that will sort everything that is above a variable ascending and everything below the variable descending. For example if the number is 5, direction is 1 and my list is [1,2,3,4,5,6,7,8,9,10] the output should be [6,7,8,9,10,5,4,3,2,1], if the direction is -1 and number is 5 again, the list should be [4,3,2,1,5,6,7,8,9,10], does anyone have any ideas how I can achieve this ? I'm writing this in Java. [link] [comments] |
How do I convert a very large base36 number into base10 using Python? Posted: 18 Feb 2020 12:53 AM PST By very large I'm talking about something like a 500 character base36 number, how can I do this in Python? [link] [comments] |
how to write junit tests for payment gateways (Stripe, Paypal) Posted: 18 Feb 2020 07:51 AM PST language : java/spring a payment gateway requires the following things for charge creation
any example code will be very handy [link] [comments] |
Making Something Like Archillect Posted: 18 Feb 2020 11:00 AM PST So im very new to all of this and ive given myself the goal of eventually making something like the twitter bot archillect and i was wondering what language would be best to learn for something like that [link] [comments] |
Need help understanding microservices components Posted: 18 Feb 2020 10:11 AM PST |
Mongo: Create a complex query with a hasMany relationship Posted: 18 Feb 2020 10:09 AM PST I'm creating a query on the group collection to find all groups that contain at least one member. Is this query possible? Or, will I need to query for all groups then filter it by performing another query with find at least one member? filter it down with another query into the member collection [link] [comments] |
You are subscribed to email updates from AskProgramming. To stop receiving these emails, you may unsubscribe now. | Email delivery powered by Google |
Google, 1600 Amphitheatre Parkway, Mountain View, CA 94043, United States |
No comments:
Post a Comment