31,002 Topics

Member Avatar for
Member Avatar for Sofia Ann
Member Avatar for rproffitt
0
48
Member Avatar for Uzo J

How would you write this into pseudo code #include<cstdio> #include<cstdlib> #include<iostream> using namespace std; int main(int nNumberofArgs, char* pszArgs[]) //variables string var, var1; float cm, mile, kilometer, inch, meter, AU, fahrenheit, celsius, foot, quit, i; //program i = 1; while (i <= 1000000000) cout << "Enter the starting unit. For …

Member Avatar for Reverend Jim
1
67
Member Avatar for Silly_2

Hello there, I am trying to calculate the shot, the value, and the score in my Archery Target Program. But I have no such luck. Would anyone be able to help me?

Member Avatar for Reverend Jim
0
69
Member Avatar for Williams Brown
Member Avatar for olong tea

This questions contains probability and I dont know how to work with it in Java import numpy import random def cup_game(): cashprice = [0.5, 1.0 , 2.0 , 5.0] n_turn = numpy.random.randint(5,11) n_mult = numpy.random.randint(3,6) cups = list(range(0,15)) x = numpy.random.choice(cashprice, 15, p=[0.3, 0.4, 0.2, 0.1]) x = list(x) turn …

Member Avatar for JamesCherrill
0
90
Member Avatar for Aarya_1

and was trying to find a way to make bubble sorting short as it is wayyy to long? so can anyone show me a code to do that?

Member Avatar for Reverend Jim
0
20
Member Avatar for olong tea

Hi, I am new to Java but familiar with python, I need to convert my code from python to Java can anyone help me? Much appreciated! import random suits = ['C', 'S', 'H', 'D'] val = list(range(1,14)) class Card: def __init__(self, suits, val): self.suit = suits self.value = val def …

Member Avatar for JamesCherrill
0
190
Member Avatar for asqinanuramni

hello, I am currently struggling so bad in understanding Java and how to implement the codes. I have to implement two subclasses for Canadian and US postal code in Java. For Canadian Postal code, a valid postal postal code has the rule: positions at 0,2,5 are letters. Positions at 1,4,6 …

Member Avatar for JamesCherrill
0
126
Member Avatar for Java5

**Introduction** You know that being effective is the key to success in any business domain. However, you may be wondering how to improve employee performance. In order to do this, it’s important to have tools at hand that will help you measure and track employee performance in real-time and act …

Member Avatar for Duncan_5
1
157
Member Avatar for Programmer18

Hi. So I want to open a application from Java code and open a new terminal for that application also through Java code. We can open the new terminal manually by entering ctrl+alt+t. But I need to do this via code without entering any keys. Can anyone suggest something?

Member Avatar for odeskavita
0
96
Member Avatar for UWInsure

Hello All, We have designed our system and integrate lots of opensource code into a single use system. All the inter connectivity are through APIs. Problem is, it's getting messy each day. We have been looking into Kong and Apigee. Anyone has experienced into situation like such? We have over …

Member Avatar for Dani
0
58
Member Avatar for dimitrilc

## Introduction ## In the last tutorial, we learned [how to set up our own RabbitMQ exchanges and queues](https://www.daniweb.com/programming/web-development/tutorials/538620/how-to-create-exchanges-and-queues-in-rabbitmq-server). In this tutorial, we will learn how to send messages to our custom **daniweb-exchange**. ## Goals ## At the end of the tutorial, you would have learned: 1. How to send …

1
451
Member Avatar for MagnusTheRed90

I have a question about encryption. So I have a code sample that has a key size being chosen, something like 32 bits or something, and I am basically either filling the key size buffer with the password and then zeroes, or null bytes, or a word repeated over and …

Member Avatar for adajames
0
131
Member Avatar for Deyns

HI GUYS I'M DEEPLY DESPERATE TO KNOW HOW TO CONVERT THE CODE FROM PHYTON TO JAVA, MY TASK IS DUE TOMORROW PLEASE HELP MEEEEE T_T

Member Avatar for adajames
0
146
Member Avatar for queency zyrel

Create a java application that will convert unit length from Metric to English system. The user will be asked to enter a Metric unit and then it will display the equivalent value to unit of English System. Use metric system like centimer, diameter, meter, etc. while use English system such …

Member Avatar for adajames
1
103
Member Avatar for queency zyrel

Create a simple java calculator console application that will use the four (4) basic math operators: Addition, Subtraction, Multiplication and Division. If conditional statements will not be use since it wasn’t discussed yet,

Member Avatar for Dani
0
33
Member Avatar for emmamark

I am attempting to write a program that will take a word as input from the user. The program will then find all of the words that can be used from the letters in the word the user inputted. A letter cannot be used twice if it only appears in …

Member Avatar for toneewa
0
204
Member Avatar for Ashwin01

![JD522_FA2_2.PNG](https://static.daniweb.com/attachments/4/1977355aeec12a9a2dfbe72584965be3.PNG) ![JD522_FA2_1.PNG](https://static.daniweb.com/attachments/4/79856a328e3fe67011afb484bb9c654a.PNG) ![JD522_FA2_3.PNG](https://static.daniweb.com/attachments/4/d9bc25423e0da12339e15aaee0f160ab.PNG) ![JD522_FA2.PNG](https://static.daniweb.com/attachments/4/90c9dac41812ac074849fe92617446a2.PNG)

Member Avatar for Dani
0
92
Member Avatar for jnbgames.dev

The program below is written in **Java** and is used to develop a Web Server that supports these status codes: **200** OK, **302** Moved Temporarily, and **404** NOT FOUND. The code can emulate an **HTTP** server in your local machine. Let me know if you find the code below helpful …

Member Avatar for JamesCherrill
1
158
Member Avatar for Ashwin01

Create a program called staffSalary using GUI Java and add a class named Staff that will determine the monthly payment amount of and return a specific staff description. The staff are getting paid differently base on the rate and numbers of hours worked. The staff also have different description based …

Member Avatar for Reverend Jim
0
56
Member Avatar for Dysiah

I need help to create a class named rectangle that contains -fields for length and width -setters and getters for the fields -a constructor that accepts length and width as parameters -an overloaded 0-arg constructor that sets field values to 0 -a method named computeArea that accepts no parameters and …

Member Avatar for Dani
1
170
Member Avatar for sarah_15

I need help to create a program that will accumulated sales for any given month. The total for each month will be stored in an array. There can be more than one entry for any given month and they do not have to be entered in any order. After all …

Member Avatar for JamesCherrill
0
3K
Member Avatar for dimitrilc

## Introduction ## While **Functional Interfaces** and **Function Types** are used to declare the types of a function, **Function Literals** create the actual implementations of these types. In this tutorial, we will learn what Kotlin **Function Literals** are and how to create them. ## Goals ## At the end of …

Member Avatar for Klint
2
183
Member Avatar for dimitrilc

## Introduction ## Whenever I want to express method parameters, return type or variables as a *method* in Java, I often find myself having to do a bit of work: 1. If I cannot remember which pre-made **functional interface** to use, then I will have to look up the list …

1
131
Member Avatar for dimitrilc

## Introduction ## When working on Java applications, it is very likely that you will run into JDBC at some point. While you are unlikely to have to work directly with JDBC when using frameworks, it is still important to know how the connection is established and how queries are …

Member Avatar for dimitrilc
2
144
Member Avatar for Zunnie

You must write a small application in JAVA for items and their prices. Your program must: 1. Create an array of item names. Use the following item names: Bread, Milk, Butter, Chips, Honey, Soap, Towel, Carrots, Beans, Samp, Dress, Pants, Shoes, Socks. 2. Create an array of item prices. Use …

Member Avatar for Reverend Jim
0
264
Member Avatar for rishabs

User interface (UI) design is a process used by designers to create interfaces in software, such as computer devices, that focus on appearance or style. Designers want the interfaces to be easy to use and user-friendly. User interface design covers graphical user interfaces and other forms - such as voice-controlled …

Member Avatar for kasiamizera
2
280
Member Avatar for Programmer18

I don't want to pass ssh key through a file. I want to pass it along with the ssh command only along with user@ip. Can I modify that ssh command? Can anyone provide me the command to pass rsa key along with user?

Member Avatar for rproffitt
0
60
Member Avatar for dimitrilc

## Introduction ## When following tutorials on Daniweb, you might have run into one that requires knowledge about **Dependency Injection** as a prerequisite. People might also sometimes use the term **Inversion of Control** interchangeably with DI. These terms are related to one another, but they are not the same. In …

2
177
Member Avatar for dimitrilc

## Introduction ## Java annotations are often used to provide extra information for compilers, IDEs, and build tools. The extra information is often used to enhance the development cycle, such as reducing boilerplate, eliminating repetitive code, or warning against unsafe usage or mistakes. This tutorial aims to teach you the …

2
103

The End.