« first day (2885 days earlier)      last day (1431 days later) » 

00:01
RELOAD! There are 7477 unanswered questions (89.4853% answered)
2
0
Q: Connect-Four winner-checking algorithm

Scotty JamisonI'm trying to practice some functional techniques. I haven't worked much in Haskell, so any language-specific tips would be very appreciated, but what I care for even more are general tips towards my approach that I can carry between functional languages. Performance is not a big concern of mine ...

00:23
Since this is a complete working program, you should probably ask this on codereview. Make sure to check what kinds of questions are on-topic on that site first. — cigien 57 secs ago
Ah, OK. Should I just copy-paste this question over on codereview? — Mike Smith 46 secs ago
00:42
I’m voting to close this question because it needs to be on codereview.stackexchange.com — Mike Smith 19 secs ago
00:58
0
Q: Compressing a vector into a specific range

Mike SmithI want to solve the following task --- I am given a vector of integers (For example: {1, 3, 10, 6, 3, 12}). I want to 'compress' this list, where the numbers in the vector will be replaced with corresponding numbers such that the new vector only contains the numbers 0 through n - 1 where n is the...

01:16
possible answer invalidation by Antonin GAVREL on question by Antonin GAVREL: codereview.stackexchange.com/posts/258772/revisions
 
2 hours later…
 
1 hour later…
04:18
0
Q: Find number of islands: Super slow compared to top answers on Leetcode

qotsa42I am on my second iteration of the famous "Number Of Islands" graph problem on Leetcode. https://leetcode.com/problems/number-of-islands/ Given an m x n 2D binary grid grid which represents a map of '1's (land) and '0's (water), return the number of islands. An island is surrounded by water and ...

05:08
0
Q: C function that emulates string concatenation operator '+' in Python or Go

debdutdebI'm working on a project of mine which required multiple calls to strncat(), and it came to me that it'd have been much easier if C also had something like "file://" + getenv("HOME") + filename for string generation. So I built a function that works in a similar fashion, it is a variadic function...

 
1 hour later…
06:31
I’m voting to close this question because this seems to belong on Code Review, if anywhere. It also needs to be properly traced and profiled before consideration. — Prune 36 secs ago
Monking
 
2 hours later…
08:28
0
Q: how to store a string to a structure variable and print it in C?

StutterSo we were tasked to create a function directory** getdirectory(int n)that reads n lines, each line containing the name, age, and birth to be stored in an array of variables of type directory and returns a pointer to an array of directory pointers (yeah i know its confusing af). My problem, I bel...

 
2 hours later…
10:08
Maybe you can ask this question in codereview.stackexchange.comTito Sanz 35 secs ago
 
1 hour later…
11:31
I’m voting to close this question because it belongs on codereview.stackexchange.comTed Lyngmo 15 secs ago
If you have working code and are looking for a review then codereview.stackexchange.com may be the right place to ask. Be sure to read through their help center first to make sure your question is on topic. — Retired Ninja 27 secs ago
@user143252 I don't think there's an automatic migration to the codereview site so you'll have to copy/paste your question. — Ted Lyngmo 40 secs ago
 
1 hour later…
12:37
0
Q: Eslint Arrow function has a complexity of 21. Maximum allowed is 20

MansouriAlaHey guys I got a linting error I wanna know why is it too complex?? and what happens if I just split it into multiple functions is that performant ?? as I know we always have to write minified code so if we split it into multiple functions it will consume more space (bits) and more excecution tim...

 
1 hour later…
13:48
Monking
 
1 hour later…
15:17
Generally, only questions about specific bugs are allowed here. Our sister site Code Review permits questions about how to improve working code. — Charles Duffy 6 secs ago
 
1 hour later…
16:32
For now, I'm voting to close this question as after some thought it is probably opinion-based. Maybe I'd ask this on CodeReview in retrospect — Nick Bull 5 secs ago
This is not a good candidate for code review either. You're not requesting a code review, you're asking what to name a function. — Patrick Roberts 37 secs ago
16:47
0
Q: Java - Pong Game project

StompkI tried to make a Pong game in Java. It's my first game I have ever programmed, and I would be very pleased if You would take the time to advise me on what I could do better next time. Thank you so much :) . Here is my code: Start.java: import java.awt.EventQueue; public class Start { public st...

17:12
0
Q: Date program for xv6- improvement and testing

jrbobdobbs83This is my first post on this forum. I have read the guidelines and will try to adhere to them, but I apologize if I miss something. The code I am posting is intended to duplicate the output of "date -u" in the XV6 OS. It does this, with the exception of dates before the 1700s (This wasn't rele...

17:37
0
Q: Open adressed, double hashing hash table

soulpower11I just started learning about hashtable and have an assignment to implement an open addressed hashtable with double hashing probing, It seems to not pass some hidden test cases and I am not sure what I have done wrong. Will be nice if someone can spot the mistake in my implementation. #include <s...

You may want to post to Code Review. — Thomas Matthews just now
18:14
Hello Charles Duffy, it's amazing to know about the Code Review! I didn't know about that! All my doubts I find the answers here on StackOverflow. Thank you so much. — Luiz Rodrigues 35 secs ago
18:27
0
Q: Best Practice: creating a nested associative array JSON in PHP

TolaniIt's been a while I have been on here and I hope I still understand the rules😊. I have recently started learning PHP and WordPress for a Whatsapp Chatbot integration. I have created a webhook on my WordPress site that returns a JSON, which is consumed by Google Dialogflow(Chatbot engine). For ex...

19:07
I’m voting to close this question because it belongs on codereview.stackexchange.comteylyn 24 secs ago
19:20
Don't ask for CR on Stack Overflow. Stack Overflow is better suited for practical programming questions about specific issues. Try [CodeReview.StackExchange.com] (CodeReview.StackExchange.com) for code reviews. — Jake White 44 secs ago
20:08
0
Q: Typescript: How to type props on wrapper component that implements formik

Cristian FlórezWhat I have I want to create a reusable Input component using Formik and Typescript, to avoid repetition of some properties: import React from 'react'; import { useFormikContext } from 'formik'; import { Input as UIKInput } from '@ui-kitten/components'; import { InputProps } from '@ui-kitten/com...

20:33
0
Q: Function measuring time of another function

ThomasLI wanted to have a function called timeit which can measure the time of execution of n iterations of any other function. I still learning C++ but I come up with that : Any thought ? #include<chrono> using namespace std; template<typename output, typename ...ArgsT, typename ...Input> double time...

20:58
0
Q: I cant reference MY CSS STYLE SHEET INTO MY HTML ON MY FTP

Lizandro DuenasThis is an issue I didn't have one vs code because I could just type in the location of the style sheet into my href (i.e. href = "assets/css/main.css". But now on my ftp--I'm using Monsta--the referencing seems to be different. I read something about an ftp link using my username and password (i...

0
Q: Checking whether a graph is 2-colorable with BFS

TabrisI'm trying to check whether a graph is 2-colorable or not using BFS algorithm. The program works for every graph I have checked so far, but using count variable seems wrong for some reason. What could I improve? Also, is it possible to represent a graph of string vertices without using map<>? Her...

 
1 hour later…
22:13
0
Q: JavaScript: I am writing a simple wrapper around fetch

JojiI am writing a simple wrapper around fetch. async function apiCall( endpoint: string, { data, headers: customHeaders, ...customConfig }: { data?: Object; headers?: Object } = {} ) { const config = { method: data ? 'POST' : 'GET', body: data ? JSON.stringify(data) : und...

 
2 hours later…
23:54
0
Q: How to simplify a discord bot in Python that updates and hosts a website for me by cloning from GitHub

TaggagiiAfter a bit of struggling I've come up with the code import discord import os import subprocess as sub import psutil client = discord.Client() my_path = os.getcwd() program_instance = False currently_installed = os.path.isdir("web-application") def run_command(command): value = sub.Popen(...


« first day (2885 days earlier)      last day (1431 days later) »