# All Questions

10 views

### how to get number with Scanner? (from 0-100) [on hold]

i know how we write Scanner code like this: Scanner s=new Scanner(System.in); but I don't know how I can get a number with Scanner.... thank you so much
10 views

### atof implementation

I have implemented the atof function. Here is my implementation ...
6 views

### Please help me by reviewing my code & suggesting improvements/fixes for my personal CMS, which I am currently using for learning.

I have included all of my core files below. Can you please review them, and leave feedback (eg - improvements, fixes, etc). Thanks. dbc class (Database connection, functions, etc): ...
14 views

### Preventing numbers from showing up in scientific notations

We have a StreamBuffer class which is not inherited from std::ios_base (or some of it's derivatives such as ...
6 views

### Convert reader to list of class

Class Student { Int studentId, List<ClassB> Books, Bool IsPassed } Class Book { Int bookId, List<int> pages } I am creating a list ...
8 views

### Parse JSON data of upcoming fixtures of Chelsea FC

This program makes a call to an API (http://api.football-data.org/) and obtains data for fixtures of Chelsea FC for the next 100 days in JSON format. The JSON is parsed into a Java object and then ...
24 views

### Longest Substring in Java

This is my function for determining the Longest Substring between two strings in Java. ...
11 views

### Partition iterator in Java

Given a list of $n$ objects and an integer $k \in \{ 1, 2, \dots, n \}$, this iterator generates all possible ways of partitioning the elements in the list into exactly $k$ disjoint, non-empty ...
16 views

### Display students of specific age using struct [on hold]

My task for uni is to create a program using structures. In this program I have to make an entry of students, their name, birth date and group (a random number). And I have to search the students ...
11 views

### How to validate a model that requires database access

Let's say I have this User model. ...
35 views

### Permutation iterator in Java

I have this class that iterates over all permutations of an input list: PermutationIterable.java: ...
8 views

### Apache HttpClient for Web Application [on hold]

I am trying to create a web application which will consume a lot of other RESTful apis. I am using Apache Http Components for consuming the apis. The plan is to have a Singleton class which will ...
16 views

### Generate Subsets Of K Elements From A Set Of Strings

This is the task: Write a recursive program, which prints all subsets of a given set of N words. Example input: words = {'test', 'rock', 'fun'} ...
15 views

### Null Reference Exception was unhandled [on hold]

So, as a beginner in C# I started building the black jack game with code only. So after creating the deck class i tested my code to check if it works so far: ...
12 views

### Display Calendar using LOOP (The user picks what DAY to start)

Desired output: Can I get an shorter version of this code? Because I know there is. My instructor just wants me to figure it out my self :( I need your help guys :) ...
15 views

### Recurring tasks in ASP.NET MVC

I have 2 alternatives for executing recurring tasks in ASP.NET MVC. We just need to add some code in Global.asax First alternative: ...
31 views

### Function that assigns names to a struct using strtok

I worked around using strtok function so to assign first name and last name to a struct PERSONNE from a ...
145 views

### Email a notification when detecting changes on a website

The text of a website is checked in a given time period. If there are any changes a mail is sent. There is a option to show/mail the new parts in the website. What could be improved? ...
22 views

### Basic TicTacToe game in java

I was assigned to create a simple Tic Tac Toe game in java for class, and here is what I got. I would like to know how the code could possibly be shortened without using really advanced topics since I ...
33 views

### Finding if the tree is balanced or not

Can someone please review my code and let me know, if there is some bug or the improvement scope. ...
35 views

### Student data parsing application

My application takes a .csv (comma separated values) file and serializes the data into a binary file. Then it converts the binary file back to a .csv file (identical to the original file). For ...
168 views

### Python exception handler to recommend package

Consider this python 3 snippet, where when an import exception is raised, a string 'e' is created that says: "No module named ' packageName'". The goal is to simply say on exit, that the import error ...
23 views

### Project Euler 18/67 : Maximum Path using Memoization

Problem statement of PE18 is : ...
21 views

### 0-1 Knapsack in Java

I'm looking for advice on coding practices in general. ...
23 views

### Walking a directory in Haskell

I wrote a function that recursively walks a given directory. ...
21 views

### 100 chairs in a circle problem solving with Angular.js and visualization

Here is the problem statement: Take a second to imagine that you are in a room with 100 chairs arranged in a circle. These chairs are numbered sequentially from One to One Hundred. At some point ...
10 views

### asynchronous web crawler python [on hold]

I am writing a small crawler using python3.5. The first version I wrote worked fine but it was too slow (single thread). I googled and found some ways of speeding up things. I tried implementing ...
9 views

### Iterative Calculation

This Google Sheets script performs an iterative (circular) calculation to find values based on a gross percentage of project cost. Range names are used so that users can add/delete rows/columns and ...
28 views

### Simple Blackjack/21 game in console

I made a simple Blackjack/21 game in C++. It does not use any fancy graphics, just the console output. It is as simple as it can get. ...
24 views

### How do I increase responsiveness of this code on an Arduino?

This is the code in its entirety, how could I make it so that I functions faster... It currently is on an arduino that should not be so unresponsive. Any help would be appreciated! I am using three ...
33 views

### Happy Number Counter

Task Write an implementation that determines the count of happy numbers between a given start and end value. Implementation ...
23 views

### Connection pool for java.sql.Connection

I have made a connection pool for SQL Connection objects. The purpose of this object is to provide multi threaded support for the accessing of the underlying ...
38 views

### Matching parenthesis

This is a simple implementation of a parenthesis-matcher. Given an expression, I want to find out if it is balanced.For example, the expression '{{[[()]]}}' is balanced while '{]{{}}]]' is not. I will ...
15 views

### Sporadic div positioning using Isotrope

I am currently using jquery + "isotrope" to make an image gallery where images can be filtered using "data-filters". But "Isotope" uses grids to organise the divs but I would like something like the ...
170 views

### Print all anagrams together in a sentence in Java

I know a lot of memory is being used, but how do I make this more efficient in space(and time) . ...
23 views

### Shortest knight path

In preparing a review of this question, I decided to rewrite the code from scratch using a more object oriented approach as I suggested in my review. To recapitulate the problem statement, we are ...
19 views

### Messing with for-loops [on hold]

So I'm new here. Hello. I've been working on CodingBat, and I know how to get the answer to this problem another way, so that's cool, but can someone PLEASE explain to me why this code isn't returning ...
9 views

### WCF service architecture when SQL Server direct table access is not allowed

Part of my job is to maintain an old application written in Silverlight talking to a WCF service which in turn fetch/persist data into a SQL Server database and in a BI cube. Most of the security is ...
47 views

### Unit converter application

I am working on an Android unit converter application, but I came to the point where I have to assign the formulas to the calculation method. At the moment I am ...
16 views

### Creating a new JFrame on label click

So I've been looking for examples on the internet for a while now and this seems the most common way everyone is suggesting, but now I ask is there a better way to make a new jframe pop up on click ...
41 views

### Extracting price statistics from a CSV file

I got the following task to solve: ...
33 views

### Recreating a URL string

This is what my viewObject looks like: ...
31 views

### Front End Web exercise, no HTML

I was given the following instructions Using the below HTML, using ONLY CSS, JavaScript or jQuery create the following (see attached gif animation): ...
27 views

### Combination generator in Java - 2nd iteration

I have refactored the previous combination generator, and now it is an iterator returning combinations as lists. It hides larger constant factors as the previous version, yet it is really easy to use: ...
23 views

### Minigame Manager (Spigot plugin)

So recently, I decided that big Minecraft minigames servers such as Mineplex and Hypixel have a huge advantage on other servers - They have a full API made by their team to make minigame additions ...
24 views

### Spoj Problem - HPFORF

This question is giving TLE for my code in Java. Same algo is working in c++. Wanted to know some optimisation in algo or code as One user has solved this problem in java also. ...
44 views

### Making a lot of requests with MySQL while trying to keep good performace

This is what the code does: Check if the user's website exists and is active. After checking the user IP already exists and if the weather 24 hours have passed, if so it deletes the IP database. ...
39 views

### Finding smallest number of moves

We are given a map of sides of length n and m (both n and m are less than 1000), divided into n*m fields (squares of side 1). The map looks (for example) like this: ...