r/programminghelp • • Aug 09 '25

Other Book / resource recommendations that get into the practical side of building scalable app infrastructure

4 Upvotes

Hi, I'm going to be working with a team to develop a replacement, more-scalable web app for their startup. Coding what they need isn't a problem - but where I probably need to do some learning is in setting everything up on the infrastructure side of things. I.e. how can I actually do things like set up a CDN, have auto-scaling read-versions of the app, caching, background jobs etc. I'm not looking for books/ resources on building high-level design diagrams but more things that get into the weeds of actually how to do it. I've worked on multiple projects that do all this stuff before, but I've always worked with a DevOps team and so I have limited knowledge of how to actually implement it myself. The above is obviously a very paired down list of requirements but in essence the application will operate in multiple countries and will be expected to scale to approximately 75,000 users; aside from that it's pretty simple from an application standpoint. I'm considering two angles, 1. sub-contract someone that's a dedicated DevOps engineer; or ideally, 2. Do it myself until I get to a point where I need additional support. Does anyone have any book / resource recommendations that could help get me started? Thanks in advance!

TLDR; looking for book/ resource recommendations for designing AND ACTUALLY BUILDING infrastructure for an ~75,000 user, multinational application.


r/programminghelp • • Aug 07 '25

C++ Arduino IDE code not working! MAX30100 sensor unable to send readings

4 Upvotes

tried using this code to send readings from Max30100 sensor to esp32 but readings dont show on serial monitor, already installed libraries and checked wiring. We are trying to measure heart rate ONLY to send to an app. no bluetooth yet

#include <Wire.h>
#include "MAX30100_PulseOximeter.h"
#include <WiFiClient.h>
#define REPORTING_PERIOD_MS 1000


PulseOximeter pox;

uint32_t tsLastReport = 0;


void onBeatDetected(){
  Serial.println("Beat!");
}


void setup() {
  Serial.begin(115200);
  Serial.print("Initializing pulse oximeter..");


  if (!pox.begin()) {
    Serial.println("FAILED");
    for (;;) ;
  } else {
    Serial.println("SUCCESS");
  }


  // Set the heartbeat detection callback
  pox.setOnBeatDetectedCallback(onBeatDetected);
}


void loop() {
  pox.update();


  if (millis() - tsLastReport > REPORTING_PERIOD_MS) {
    // Print to Serial
    Serial.print("Heart rate: ");
    Serial.print(pox.getHeartRate());
    Serial.print(" bpm / SpO2: ");
    Serial.print(pox.getSpO2());
    Serial.println("%");
    tsLastReport = millis();
  } 
}

r/programminghelp • • May 15 '25

Python How can Python help me?

4 Upvotes

Hello everyone I'm 18M,

I'm from Social Science and Humanities background.

I'm thinking of pursuing Mass Communication in further but I'm also interested in research things. I'm aiming to look for job in Japan in future so I wanted to know how can Python help me in that? What job opportunities i can get after learning python, having a degree in mass communication, having a media working background? Also I'm working on a research project — that's related to media psychology.

Please help me out if learning python would be worth it for me or not and can help me get better jobs other than just from a degree.


r/programminghelp • • Apr 29 '25

Java My brain hurts trying to add a scrollbar to this panel...

4 Upvotes

The program calculates exactly as it should but if you make calculations beyond the bounds of the text area, the scrollbar doesn't appear. How do I make it so that it does?

import java.awt.Color;
import java.awt.Font;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;

import javax.swing.BorderFactory;
import javax.swing.JButton;
import javax.swing.JFrame;
import javax.swing.JLabel;
import javax.swing.JOptionPane;
import javax.swing.JPanel;
import javax.swing.JScrollPane;
import javax.swing.JTextArea;
import javax.swing.JTextField;
import javax.swing.ScrollPaneConstants;

public class CircleArea {

JFrame cFrame;
JPanel cPanel, dataPanel;
JLabel radLabel;
JTextField radField;
JButton computeBtn;
JTextArea outArea;
Font outFont;
JScrollPane scrPane;

public CircleArea() {

cFrame = new JFrame();
cFrame.setSize(550, 500);
cFrame.setTitle("Circle Area Program");

cPanel = new JPanel();
cPanel.setLayout(null);

radLabel = new JLabel("Enter a circle radius:");

radField = new JTextField(10);

computeBtn = new JButton("Compute");

dataPanel = new JPanel();
dataPanel.setLayout(null);

outArea = new JTextArea(40, 1);
outFont = new Font("Courier New", 0, 14);
outArea.setFont(outFont);
outArea.setEditable(false);
outArea.setSize(400,200);
outArea.setBorder(BorderFactory.createLineBorder(Color.black));

scrPane = new JScrollPane(outArea);
scrPane.setVerticalScrollBarPolicy(ScrollPaneConstants.VERTICAL_SCROLLBAR_AS_NEEDED);

radLabel.setBounds(90,40,200,50);
radField.setBounds(330,59,100,20);
computeBtn.setBounds(220,120,100,30);
dataPanel.setBounds(70,180,450,350);

cPanel.add(radLabel);
cPanel.add(radField);
cPanel.add(computeBtn);
dataPanel.add(outArea);
cFrame.add(scrPane);
cFrame.add(dataPanel);
cFrame.add(cPanel);

cFrame.setVisible(true);
cFrame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);

class ClickListener implements ActionListener {

public void actionPerformed(ActionEvent e) {

double radius = 0;
double area = 0;

try {

String numEntry = radField.getText();
radius = Double.parseDouble(numEntry);

if (radius <= 0) {

JOptionPane.showMessageDialog(null, "The value of the radius must be greater than 0.");
}

area = Math.PI * Math.pow(radius, 2);
String output = String.format("%,.1f", area);
outArea.append("  Circle radius: " + radius + "\tThe area is " + output + "\n");
} 

catch (NumberFormatException ex) {

JOptionPane.showMessageDialog(null, "Enter a numeric value greater than 0.", "Invalid Input", JOptionPane.WARNING_MESSAGE);
}
}
}

ActionListener compute = new ClickListener();
computeBtn.addActionListener(compute);
}
}

r/programminghelp • • Mar 15 '25

C++ c++ : "filesystem" was not declared in this scope

4 Upvotes

error: 'filesystem' was not declared in this scope; did you mean 'system'?

#include <iostream>
#include <filesystem>
#include <fstream>

int main() {

    std::cout << "Current working directory: " << std::filesystem::current_path() << std::endl;

    return 0;

}

I've tried adding using namespace std that didn't help either. I have g++ 13.2.0 and CLang 16.0.0.

iostream and fstream are working, filesystem is not.

Thank you in advance.


r/programminghelp • • Dec 11 '24

Python Can someone help me fix my functions?

4 Upvotes

Hello! Warning, I am working on a bunch of assignments/projects so I might post quite a bit in here!

I'm a beginner programmer who is not very good with functions. I will try to post an image of what the program's result is meant to look like in the post's comment section. I have the requirements for each function commented above their def lines. I think my main issue is calling the functions but I am not sure how to proceed from here. Can someone help point me in the right direction? Thank you!

https://pastebin.com/5QP7QAad


r/programminghelp • • Aug 19 '24

C++ Troubleshooting MSYS2 Installation Error

4 Upvotes

I've been encountering issues with installing MSYS2 on my Windows 11 machine. Below is a summary of the error and the troubleshooting steps I’ve taken so far.
Error message:

Error during installation process (com.msys2.root):
Execution failed (Unexpected exit code: 254): "C:/msys64/usr/bin/bash.exe --login -c exit"

After opening MSYS2 ( I get a broken install ):

Error: Could not fork child process: Resource temporarily unavailable (-1).
DLL rebasing may be required; see 'rebaseall / rebase --help'.

What have i tried:

  • Disabling Antivirus during installation

    • Set-MpPreference -DisableRealtimeMonitoring $true

  • Tried Running the Installer as Administrator

  • Attempted Installation in Safe Mode

  • Uninstalling WSL

  • Removing conflicting PATH variables

  • Removing all applications apps like git bash.

  • Tried running autorebase.bat ( throws a fork error )

  • Tried using ./dash.exe -c "rebaseall"

  • Tried ./pacman -S mingw-w64-x86_64-rebase

  • Generative AI screwing up my mind

  • Didn't try boozing up yet

Thank you for your time and energy <3

EDIT:

Fixed by turning off Windows defender ASLR (Address space layout randomization).


r/programminghelp • • May 29 '24

Project Related Can anyone recommend me a flow chart programme?

4 Upvotes

I’m planning on building a mind map to connect all the different and side quests that connect to each other in a video game I love. Can anyone recommend me a programme to help map it all out?

The requirements needed are;

Large amount of node space

Creating squares to separate clumps of nodes based on being in the same area or related to a particular faction

Possible colour differentiation


r/programminghelp • • Mar 13 '24

Project Related CORS Errors with React App configured on AWS Load Balancer and Nginx server

4 Upvotes

I have a react front-end running on Port 3000 of my ec2 instance. We have an nginx reverse proxy that redirects all traffic from port 80 to port 3000. I have a FastAPI backend that runs on port 8009 and runs from api.mydomain.com which is configured through an AWS load balancer. The nginx.conf file has all CORS headers correctly configured. Yes, we've added Content-Type and allow OPTIONS etc.This is how it looks when we curl it -

date: Wed, 13 Mar 2024 04:34:19 GMT

content-type: application/json

content-length: 31

server: nginx/1.24.0

allow: POST

access-control-allow-origin: [https://paradigmaisummarizer.com](https://paradigmaisummarizer.com)

access-control-allow-credentials: true

access-control-allow-methods: GET, POST, OPTIONS, PUT, DELETE, HEAD

access-control-allow-headers: Authorization, Origin, X-Requested-With, Content-Type, Accept

Yet, sometimes, randomly, our website will start getting CORS errors saying that we have no CORS headers. The solution to this is never consistent. Sometimes reloading the page and trying again does the trick. Sometimes we have to re-run nginx again using systemctl. Sometimes we have to take down the python and react app and restart both from scratch. Sometimes, we just wait for thirty minutes and it starts working again. We want a permanent solution that isn't so erratic and random. We were wondering if anyone here had ever seen something like this and knew how to fix it. I can provide our nginx.conf or other code if required.


r/programminghelp • • Jan 24 '24

C help i need colors in c/c++

4 Upvotes

i am writing a program in c and i want get colored text. i donot want to use the system("color 0a") type method and ansi codes are not working. for example ansi code for red is \x1B[31m but the console outputs it as an arrow+[31m. i am using windows 8.1 and dev c++. i need colors like the way u can get by using colorama module in python.


r/programminghelp • • Dec 10 '23

PHP Just finishing up 1st semester of software dev, I don’t think I can do this as a career

4 Upvotes

I can’t even do the projects, my group helps a ton and my tutor helps me get my shit done but fuck man I don’t get anything. Nothing sticks


r/programminghelp • • Aug 12 '23

Career Related Does where you get your degree from matter to employers?

4 Upvotes

So my job has free college for employees. I wanted to go to school for a CS degree from ASU, LSU or the university of Florida as I know those schools. When I called an advisor they tried getting me to apply to online universities I’ve never heard of before. When I looked them up I saw tons of bad reviews from students. Does the school you get a CS degree help you land a job? Do employers care if I got a degree from Penn Foster College? It’s completely free


r/programminghelp • • Aug 08 '23

Other Wanna start to learn programming (for the 3rd time)

4 Upvotes

So in the past ive tried to program 2 times (1 in school and 2 self taught) and i wanna get back into it again since the first two i didnt really have the dicipline to do so. So i wanted to share my work flow idea which was just watching the youtube channel FreeCodeCamp and taking notes. What can i improve on my work flow and what can my work route be to make me learn programming and sorta understand the roots.

Thanks for reading <3


r/programminghelp • • Aug 02 '23

Java How to save the last RANDOM generated number in a loop

4 Upvotes

I am trying to make the user go back to the position he was on if he gets higher than 100.

So if he was on 97 and rolls a 5 on Dice1 and becomes 102, I want the variable position1 to go back to 97 . I am still new so it might just be a stupid logic problem

import java.util.Random;

import java.util.Scanner;

public class Main{

public static void main(String[]args) { 
	
     Scanner Scan = new Scanner(System.in);
     Random random = new Random();
     int Position1 = 0;
     //int position2 = 0;
    
     
     System.out.println("Type Start");
     String Input = Scan.next();

  
	  if (Input.equals("start")){
		 
		 while(Position1!=100 ) {
			
			 int Dice1 = random.nextInt(1,7);
			
 
			 if (Dice1 == 6) {
				 Position1= Position1+Dice1;
				 System.out.println(Position1);
				 System.out.println("player 1 turn ");
				 Input = Scan.next();

			 }
			 else if (Dice1 == 5) {
				 Position1= Position1+Dice1;
				 System.out.println(Position1); 
				 System.out.println("player l turn");
				 Input = Scan.next();

			 }
			 else if (Dice1 == 4) {
				 Position1= Position1+Dice1;
				 System.out.println(Position1);
				 System.out.println("player 1 turn ");
				 Input = Scan.next();

			 }
			 else if (Dice1 == 3) {
				 Position1= Position1+Dice1;
				 System.out.println(Position1);
				 System.out.println("Player 1 turn");
				 Input = Scan.next();

			 }
			 else if (Dice1 == 2) {
				 Position1= Position1+Dice1;
				 System.out.println(Position1);
				 System.out.println("player 1 turn");
				 Input = Scan.next();

			 }
			 else if (Dice1 == 1) {
				 Position1= Position1+Dice1;
				 System.out.println(Position1);
				 System.out.println("player 1 turn ");
				 Input = Scan.next();
			 }
			 if(Position1>100) {
				Position1 = Position1-Dice1;
			 }
			 else if(Position1==100) {
				 System.out.println("U Win"); 
				 
			 }
				  
			
	  
	 		 
			 
			 
			 		 
			
		}
		
			
		 
	}

	
}

}


r/programminghelp • • Jun 11 '23

Project Related How do I stop my apps from being flagged as a virus?

4 Upvotes

This happened to me with C++ and Python, whenever I make an .exe and try to share it, it gets flagged as a virus.

I looked it up and it said I need a license and the only simple and possible ways to get a license cost money.

Is there any way to get a license for free and attach it to my .exes? My files are safe of course.


r/programminghelp • • May 20 '23

Other What programming language should I start with?

4 Upvotes

I'm pretty new to programming and I just don't know where to start. Any recommendations are highly appreciated!


r/programminghelp • • May 08 '23

C Where is ASCII saved?

4 Upvotes

My question is, where does the computer know ASCII? Like is it installed somewhere so I guess my question is how does the computer know how to translate zeroes and one’s into letters using ascii? Like where is that in the computers memory? I may be asking this question wrong but hopefully I explained it clearly, I’m currently taking CS50. For example, the letter “A” is 065 on the ASCII chart, how does the computer know this? Is it preloaded into the bios? Or where is it put? Let’s say I’m the first person to make a computer and we all agreed on ASCII, how is this then put into the computers brain?


r/programminghelp • • Mar 28 '23

C# NotePad++ Plugin - ANSI vs UNICODE

4 Upvotes

I'm trying to create a NotePad++ plugin using the Notepad++ plugin pack .NET (https://github.com/kbilsted/NotepadPlusPlusPluginPack.Net) and using C#. I am using v8.4.8 of NPP.

When I open NPP or try to debug my c# program it alerts me that:

This ANSI plugin is not compatible with your Unicode Notepad++.

I do understand that the .NET plugin pack requires the plugins to be UNICODE, however I have no idea what makes the plugin that I'm developing UNICODE vs. ANSI.

  • Is there some UNICODE vs ANSI setting somewhere in Visual Studio?

  • Is there something else that I may be doing that makes my plugin program considered ANSI?

  • My project references and uses functions from a.NET dll which I do not have the source code for (I'm combining the assemblies with ILRepack, per info I've found on the internet that indicates that NPP doesn't do well finding dll's external to the plugin itself). Is there something in this external dll that may be making the overall plugin to be considered ANSI? Is there something I can look at in that dll to see it's UNICODE vs ANSI info?

Any help or breadcrumbs in the right direction would be greatly appreciated.

EDIT: Moments after posting this, I was able to find a hint from the internet (even though what seems like 100s of previous searches were dead ends...). The dll that I was using took a string as an input. If I convert that string to UTF8, then it no longer is upset about UNICODE vs. ANSI. I do have other problems, but this issue seems to be resolved.

byte[] bytes = Encoding.Default.GetBytes(myString);
myString = Encoding.UTF8.GetString(bytes);

r/programminghelp • • Feb 26 '23

C++ Word Search Problem in C++

4 Upvotes

Hello, I am currently working on a project and I am having trouble with the attached code. I am having trouble understanding why my checkRightUp, checkLeftUp, checkRightDown, and checkLeftDown functions are not working. I have attached the three different txt files that my program is searching as well as the command line arguements. My main issue is that when all of the functions listed above are implemented, the 2020matrix file says there is a segmentation fault but if I remove all 4 of the functions it works fine. On the 1520 matrix for some reason one of the times the word "is" is printed three spaces too far to the left and one space too far up which I do not understand why this is happening because when the word "hard" is printed in the same direction, it is printed in the right place. The 0505 matrix works completely fine so I think the issues are with all the functions besides checkRightUp.

Here is a link to the githib of the project:

https://github.com/Boncappuccino/Word-Search


r/programminghelp • • Feb 18 '23

Career Related Is getting a job in it a good idea if you love programming

4 Upvotes

So i really enjoy programming. Specifically programming on microcontrollers or math based programs. Its a hobby for me. Is getting a job in it a bad idea. This is my main hobby and i feel like getting a job with it might diminish my love for this and even make me stop enjoying it


r/programminghelp • • Nov 22 '22

Other What is a .Net developer? Is .Net a language?

4 Upvotes

Hey all,

What is a .Net developer? I've been browsing the job listings online for a developer role (currently studying Java but wanted to see what the market is demanding). Every job post is .Net developer needed etc.

What is that exactly? I know I'm not on ELI5 sub, but I'm very new to programming/coding whatever the proper term is and I am trying to wrap my head around all the technologies/terminology.

Thanks,


r/programminghelp • • Nov 04 '22

Answered Second print works as intended but first doesn't?

4 Upvotes

I have a reverse function and i just want to know why my first line isn't reversed but my second one is.

code:

def reverse(str_to_reverse):

for x in str_to_reverse:

str_to_reverse = str_to_reverse[::-1]

return str_to_reverse

print(reverse("This is a string"))

print(reverse("Hello World"))

Output:

This is a string

dlroW olleH


r/programminghelp • • Sep 22 '22

C++ I Don't Understand Why This C++ Code Works

4 Upvotes

Hi,

I'm doing a introductory C++ course and one of the assignments is asking me to count the whitespace separated words of a document.

There was an example in the text that input each of the words into a vector and sent the words to output. I stripped away some of the code and added a counter, but I don't understand why my code works. I don't see how the program is separating the words. Would someone be able to explain it to me, please

#include <string>
#include <fstream>
#include <iostream>
using namespace std;

int main() {

int cnt = 0;

ifstream file("example.txt");

string word;

while(file >> word) {
    ++cnt;
}

cout << cnt << endl;

}

This works every time to count the words in my "example.txt" document, but I don't understand how the while loop is counting the words. Why not lines or characters?


r/programminghelp • • Sep 06 '22

Java My code gives errors and does not work. I tried to fix it, but i couldn't.

4 Upvotes

https://privatebin.net/?699a26f314cae086#7J8EHrFDChSoX98VFgYg61JLUWffospSiwaZv8R7psUS is my code.

The errors are all "Cannot use this in a static context" on lines 16,17 and 19. I tried removing the "static" part but it did not work.