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
timama [110]
3 years ago
11

Write a class called Dragon. A Dragon should have a name, a level, and a boolean variable, canBreatheFire, indicating whether or

not the dragon can breathe fire. The class should have getter methods for all of these variables - getName, getLevel, and isFireBreather, respectively.
Computers and Technology
1 answer:
Alex Ar [27]3 years ago
4 0

Answer: A dragon name could be name Holls and at level 14 and can breathe fire

Explanation:

You might be interested in
Write a function that takes as input a single integer parameter n and computes the nth Fibonacci Sequence number. The Fibonacci
RSB [31]

Answer:

Following are the code to this question:

def Fibonacci(n):#defining a method Fibonacci that accept a parameter

   a = 1#defining a variable a that holds a value 1

   b = 1#defining a variable b that holds a value 1

   if n <= 0:# Use if to check n value

       print("invalid number")#print message

   elif n == 2:#defining elif that check n equal to 2

        return 1#return 1

   else:#defining else block

       print(a)#print value of a

       print(b)#print value of b

       for i in range(2,n):#defining for loop to calculate series

           s = a + b# add value in s variable

           a = b # interchange value

           b = s# hold s value

           print(s)#print s value

Fibonacci(10)#calling method

Output:

1

1

2

3

5

8

13

21

34

55

Explanation:

In the above-given program code, a method "Fibonacci" is defined, which holds a value "n" in its parameter, and inside the method two-variable "a and b" is defined, that holds a value "1".

  • In the next step, if a block is defined that checks n value is less than equal to 0, it will print "invalid number" as a message.
  • In the elif, it checks n value is equal to 2 it will return a value that is 1.
  • In the else block, it will calculate the Fibonacci series and print its value.
4 0
3 years ago
How to get an object from a container in java.
Vinil7 [7]
If it stores any type of objects mixed, use Object as storage class. All classes inherit from Object and for primitives use their respective wrapper classes. Or just use one of the bazillion container classes that already exist.
3 0
3 years ago
A _ is the acknowledgment of a potential noncomformity, or an opinion regarding an issue that is not covered by a standard
sleet_krkn [62]
Assumption - hope this helped took the test and got 100
5 0
3 years ago
What is computer ? What is computer program? What is hard disk.
g100num [7]
A computer is a electronic that helps you access the internet/WiFi
4 0
4 years ago
Read 2 more answers
Sometimes, fourth-generation languages (4GLs) are called procedural languages
irakobra [83]
Hi!

In 1981, the term 4GL was actually used to refer to languages which were <em>non-procedural. </em>A procedural language does not possess <em>object-oriented </em>capabilities. 4GL's often times have OOP properties, so I believe the answer to this question is going to be <em>false. </em>=)
7 0
3 years ago
Other questions:
  • All of the following statements correctly describe an advantage or disadvantage associated with the use of Monte Carlo Analysis
    9·1 answer
  • 20 points/ When creating a storyboard, in which section do you mention how you move from one shot to the next?
    11·1 answer
  • Instead of typing out each co-worker's email address individually, you can use the Office Online People application to create a
    8·2 answers
  • Which characteristic would be best for a person seeking a career in the Telecommunications pathway?
    15·1 answer
  • Java
    14·1 answer
  • 3. What are the first steps that you should take if you are unable to get onto the Internet? (1 point)
    15·1 answer
  • Fortnite anyone? i just started tdy so dont be judgiee lol
    6·2 answers
  • Explain why, with fast moving mobiles, speed is more dominant in characterizing the use mobility pattern than direction?
    8·1 answer
  • . Write programming code in C++ for school-based grading system
    8·1 answer
  • How does the internet help you to improve your:
    15·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!