Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [beginner]

Add this tag to your question to indicate that you are new to the language of your code. This will often be taken into consideration by reviewers when assessing your code.

-2
votes
0answers
18 views

Struggling to do a math problem in PHP [on hold]

My teacher gave me a simple penny problem to use a loop to solve. You start with 1 penny on the first day it doubles for 30 days forming a cumulative total. I thought it was going well but I my code ...
4
votes
1answer
25 views

Calculator in Python3 using Tkinter

I´m a beginner developer and I chose Python as my initial language to learn. This is my very first project: a calculator using tkinter for GUI. I´ve tried to apply some OOP and modules approach, as ...
3
votes
0answers
31 views

VBA code to import data, doing lookups to detect duplicates

I have an import macro, which creates ID by concatenating cells, then I compare using VLOOKUP with another sheet if any duplicate found. It's running very slowly, so I want to know better ways to ...
2
votes
0answers
25 views

Utmost function that takes a comparator function

I'm working through Paul Graham's "ANSI Common Lisp". In Chapter 6 (p105), he introduces the idea of utility functions. He points out these are core to bottom-up programming and reusability. He ...
1
vote
1answer
77 views

A faster way to compute largest prime factor (Again, but a lot better)

I came up with this code after implementing the feedback given by @200_success. The previous one (A faster way to compute the largest prime factor) tested my patience, but still failed to give the ...
1
vote
2answers
49 views

Input class in Java

I'm a newcomer to Java (I primarily do C# ) and I have to say that they have made I/O handling much more difficult than it should have been. I am accustomed to the scenario where when I need keyboard ...
3
votes
1answer
31 views

Opening YouTube videos according to chakra cycles

I'm learning how to write code in Python. This code makes an .ini that saves different cycles adding one new operation to the previous cycle. It starts at 1;1, saves that it has run 1 cycle and will ...
8
votes
4answers
2k views

A faster way to compute the largest prime factor

I am self-learning js and came across this problem(#3) from the Euler Project The prime factors of 13195 are 5, 7, 13 and 29. What is the largest prime factor of the number 600851475143 ? ...
5
votes
1answer
72 views

Create a town administration report

I am Learning Javascript, after doing Java development for 2 years. I am doing a module on udemy which had a coding challenge which I completed and it works but wanted to get it reviewed to find out ...
0
votes
0answers
21 views

K30 CO2 sensor readings triggers URL variables [on hold]

-- Raspberry3, Python3, writing and compiling in GEANY-- The provided code for my CO2 sensor wasn't working, so i had to rewrite it. Have i done it correctly? I've borrowed some code snippets from ...
4
votes
1answer
35 views

Running AWS commands works ok, but the code seems messy and I don't like the time.sleep bit

This is what I've come up with for a class that handles parsing AWS Textract output. So far it only gets the AWS Textract output into a .txt file. ...
-1
votes
0answers
24 views

Simple Javascript card game [on hold]

I'm currently learning JavaScript and I'm working on a small project but I need your help. I've been working on this card puller website were you can pull a card and it then adds the value of the ...
-2
votes
0answers
17 views

inputMismatchException [on hold]

im designing a class that stores the name of three runners and time it took to finish the race. this class has methods that return the name of the runner in 1st, 2nd and 3rd place ...
-4
votes
0answers
25 views

I can't continue where I finished [closed]

First of all I'm a kid who found this code as a base for me and then I edited it but then whenever I load it the first time and teach it, it will save the pickled data but at the second time the data ...
2
votes
1answer
68 views

Beginning C, hangman

I have been working on this hangman game for a little while trying to get familiar with C programming. The game seems to work fine but I am looking for some pointers on my code. Are the global ...
3
votes
3answers
141 views

two integers one line calculator

I created this simple one line calculator for two numbers only where user can input any two numbers and and operator in between for example 20+45 and computer will return result of 65. ...
5
votes
1answer
81 views

Tic-Tac-Toe with changeable board size

I've created a Tic-Tac-Toe program with python which has a option to change a standard 3x3 board to NxN board. I've also created easy, hard and insane AIs. Please help me in improving the code and ...
3
votes
0answers
34 views

Recursively create a tree in Rust

This code is meant to take a rectangular area, and randomly divide it up into smaller rectangles in a binary tree. I'm somewhat new to Rust. I'm concerned mostly about the ...
4
votes
3answers
63 views

Simple BMI Calculator (Python 3)

As my first Python program I have written a simple BMI calculator. I want to know how i can improve this program. Would functions be useful? How can I improve the way that it is presented? ...
3
votes
1answer
51 views

Project Euler #5 in C++

I'm currently doing the Project Euler challenges to learn C++. The fifth problem is the following. 2520 is the smallest number that can be divided by each of the numbers from 1 to 10 without any ...
2
votes
1answer
26 views

Converting words/numbers to Discord “letter/number emojis”

I am a beginner to Python (and programming overall) and I decided that it would be funny if I wrote a program that could convert Letters/Numbers to these "Letter Emojis" in Discord. It works but I am ...
1
vote
0answers
32 views

Sliding marker on link hover and click with jQuery

The code I'm bringing forward is for a vertical menu, where I needed a marker to do the following: When hovering over a link the marker should slide down next to it. When not hovering over a link the ...
5
votes
2answers
75 views

Simulation of spring-loaded inverted pendulum

I've finally committed to moving to Python 3 from MATLAB. I'm currently porting my MATLAB code, and I'm sure I'm missing a lot of common best-practices. For reference, I'm simulating a spring-loaded ...
19
votes
4answers
4k views

Project Euler #1 in C++

I'm learning C++ and currently doing Project Euler challenges. The first challenge is the following. If we list all the natural numbers below 10 that are multiples of 3 or 5, we get 3, 5, 6 and 9. ...
2
votes
0answers
25 views

Wordpress plugin to create page-specific categories

I would love some feedback about this very simple Wordpress plugin (my first one). It's intended to create page-specific categories (via the creation of a custom taxonomy). It's working on my ...
1
vote
2answers
71 views

Statistical methods using PHP (mean, co/variance, standard deviation, skew, correlation)

Functionality This class has a list of statistical functions such as mean, variance, standard deviation, skewness, and it works okay. These functions are applied to arrays of charts data. It is an ...
0
votes
1answer
42 views

GUI that searches files using user inputted search strings [closed]

Basically, I've got a GUI where the user can select text files, enter in strings (that may or may not contain wildcards) and search those files for those strings. Currently, I take the user inputted ...
-1
votes
0answers
61 views

Formatting integers with commas (12345 → 12,345)

Beginner/occasional C tinkerer here. (Reasonably comfortable with scripting languages, tend to avoid C due to its terseness, but trying to work past that.) I happened to want to insert commas into ...
2
votes
1answer
97 views

Game to shuffle and guess a word

I'm new to C++ and while learning, I wrote a simple program that asks for a word, shuffle sthe characters and then asks another person to find the original word, given the shuffled letters. I would ...
4
votes
1answer
39 views

Comparing 2 iOS and Android versions

Please review and let me know which version is better. I'm just trying to find any caveats or better ways to accomplish the a version comparison independent from Android and iOS. Formats accepted: '1....
1
vote
0answers
14 views

Google ChartWrapper bar formatted table

The end result is a bar formatted table chart that has expanding and minimising rows. The code below works fine but I'd like to know if there is a cleaner way to achieve the same result (see JSFiddle ...
6
votes
0answers
46 views

ASCII Mandelbrot Set “image” producer

As an exercise, I decided to try implementing a Mandelbrot Set viewer that produces ASCII images. Small Example: ...
2
votes
1answer
46 views

VBA - If value in sheet1 found in sheet2, then delete data from sheet2

I have 2 sheets setup: Exclusions and Issues Issues has a list of CASE ID's and Columns that list the "Issue" Exclusions will be populated with CASE ID's that are to be excluded (and removed) from ...
2
votes
1answer
29 views

Edit button toggles modal and load data from PHP using AJAX and JQUERY

I've been working on an edit/update button that will toggle a modal that looks like this: Is there a better code for this JavaScript code that I made? ...
0
votes
1answer
31 views

Haskell: How to split the main:: IO() to a main::IO() and a function [closed]

This code is to recreate the game 'Earthworms'. The part I need help with is the main :: IO() part. I want to split this part ... ...
1
vote
0answers
44 views

Simple Asynchronous Dispatch Queue

I'm practicing C++11/14/17 and am teaching myself the STL multithreading library by writing an asynchronous dispatch queue for my simple use case. It seems to "work ok" but I want to know if it's ...
8
votes
0answers
173 views

Windows keylogger in C++

Windows keylogger in C++ Known issues: Not implementing rule of five Having to use hack to use member variables, out_, in static method Pressing caps-lock won't ...
16
votes
6answers
5k views

Check which numbers satisfy the condition [A*B*C = A! + B! + C!]

#include <iostream> #include <cmath> using namespace std; int s = 1; //Serial No. Should I use recursion for the factorials function? ...
0
votes
2answers
85 views

User interface HTML string generated using PHP

Goal This is very basic beginner script, only for prototyping, probably never to reach alpha/beta prototyping/production, is being designed/tested for performance. Its performance quality might be ...
0
votes
1answer
62 views

Combinational string search using Java

I wrote a program that receives 2 strings (Input and Search) in the Search string. The sign '+' indicates that if the substring before the '+' exists in the Input string. (The search string cannot ...
3
votes
1answer
36 views

Getting limited user input: strings and numbers

I posted part of this module earlier (here). I implemented that feedback and now am looking for another round of gut checking. Questions/Concerns I have: Does the way I've structured my functions ...
5
votes
2answers
229 views

Calculating the number of coins in money change

I wrote a program that calculates the minimum number of coins required to give a user change. One concern I have is: When do we initialize the value of a float to be negative or positive? I recently ...
4
votes
1answer
49 views

Optimizing my 2D Ising model code in Julia

I'm just starting to learn Julia, I work primarily in physics and am used to writing most of my code in Fortran90 and occasionally Python for Tensorflow (also Mathematica but that's less relevant). ...
6
votes
2answers
109 views

Simulation of a banking system with an Account class in C++

I have been learning C++ and recently I have started practicing classes. I made this simulation of a banking system with an Account class. I would like to hear feedback on my code, what is good - what ...
5
votes
1answer
59 views

Extracting watermark from a video using Python

I'm extracting a few frames from a video: Comparing the similarity or equality of pixel color (from first two images) Saving to a new image Comparing the new image (conjunction of first two images) ...
5
votes
3answers
123 views

Python coin flipper

I know this is the simplest code that you have probably ever seen but its the first thing I've ever made. Any ideas on how to improve it or add new functions to it? ...
3
votes
0answers
44 views

Bash script to setup new Debian installs - follow-up

I have this bash script I've been working on and I have updated it. I was hoping for some advice and/or input on the code. This script is run directly after a fresh install of ...
26
votes
5answers
4k views

Fishing simulator

I'm new to Python, for a school project I created a "fishing simulator". Basically, it is a use of random. I know that my code is repetitive towards the end, but I don't know how to simplify it. <...
3
votes
2answers
37 views

Sliding marker on link hover with jQuery

The following code is for a vertical menu, where I needed a marker to slide down next to a link upon hovering over said link. Therefore I needed to change CSS properties of a HTML element (the top-...
2
votes
0answers
34 views

Trying to speed up doing a regex_search function with X strings on Y files

The point of this project is to be able to create an excel configuration file where the user can input search strings and search files, both potentially having wildcards, and search those files for ...