1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Fantom [35]
3 years ago
11

Can anyone provide a good java program that shows how to implement a button?

Computers and Technology
2 answers:
horsena [70]3 years ago
7 0
No thanks, good luck though! <3
tia_tia [17]3 years ago
5 0

Answer:

Hello, this is Kyle Risso and I wrote a program for school not too long a go that can probably answer your question. This code creates two buttons that cycle through different colors.

Explanation:

The most important parts of the code are the ArrayList which implements the arrays for the different colors, but to answer your question the buttons are created using Action Listener as you'll see in the code. Hope this helps.

Download java
You might be interested in
While working on a group project, you notice something does not look right in the presentation. You call a meeting with your tea
alexgriva [62]

Answer:

Teamwork

Explanation:

4 0
4 years ago
computer has a 32-bit instruction word broken into fields as follows: opcode, six bits; two register file address fields, five b
lina2011 [118]

Answer:

a.  2^6, or 64 opcodes.

b.  2^5, or 32 registers.

c. 2^16, or 0 to 65536.

d.  -32768 to 32768.

Explanation:

a. Following that the opcode is 6 bits, it is generally known that the maximum number of opcodes should be 2^6, or 64 opcodes.

b. Now, since the size of the register field is 5 bits, we know that 2^5 registers can be accessed, or 32 registers.

c. Unsigned immediate operand applies to the plus/minus sign of the number. Since unsigned numbers are always positive, the range is from 0 to 2^16, or 0 to 65536.

d. Considering that the signed operands can be negative, they need a 16'th bit for the sign and 15 bits for the number. This means there are 2 * (2^15) numbers, or 2^16. However, the numbers range from -32768 to 32768.

6 0
4 years ago
Which type of programming language is understood directly by the computer? Assembly language Machine language Visual Basic Java
vlabodo [156]

"Machine Language"

is the answer you are looking for.
! ! ! !
V V V V

"Machine code or machine language is a set of instructions executed directly by a computer's central processing unit (CPU). Each instruction performs a very specific task, such as a load, a jump, or an ALU operation on a unit of data in a CPU register or memory."
3 0
4 years ago
Write a java program as follows Write a method called powOfTwo that takes an integer as parameter, computes, and outputs it’s sq
Kisachek [45]

Answer:

public static int powOfTwo(int input) {

 return input*input;

}

You will have to call this method in main
for printing it, write

System.out.println(powOfTwo(your number));

in public static void main(str[]args) {

}

8 0
2 years ago
Lisa and her husband would like to buy a house soon. She continuously pays bills late. How do her actions affect her and others?
stiks02 [169]
Well actually it affects her credit. Home owners would not want to sell a house to someone who doesn't pay bills on time. It shows he/she is unreliable

3 0
3 years ago
Read 2 more answers
Other questions:
  • In the lab, you performed an asset identification and classification exercise by creating a(n) __________ organized within the s
    10·1 answer
  • SP 800-14, Generally Accepted Principles and Practices for Securing Information Technology Systems, provides best practices and
    12·1 answer
  • What keyboard shortcut keys selects cell A1
    12·1 answer
  • What type of media can be edited and published by anyone?
    6·2 answers
  • Technician A says that a ratio is a comparison between two values. Technician B says that in a compression ratio, the main value
    5·1 answer
  • If you want the values in your cell to have dollar signs in front of them, _________
    8·1 answer
  • Holly has at most $828 to spend for moving from her old apartment. The moving company charges $80 per hour plus at rate of $300.
    9·1 answer
  • Create an application named StudentsStanding.java that allows you to enter student data that consists of an ID number, first nam
    12·1 answer
  • Discuss the factors which cause imbalance in the environment.
    8·1 answer
  • Who are all the fnaf characters?
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!