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
Lorico [155]
2 years ago
14

Now write the outline of a Class called BulgarianSolitaire. Remember, what does this class need to "know" and what does it need

to "do"? I want you to write pseudo code for how this Class can play Bulgarian Solitaire with 45 cards. What is a triangular number???
Computers and Technology
1 answer:
torisob [31]2 years ago
7 0

Answer:

import java.util.ArrayList;

import java.util.Collections;

class Bulgarian

{

  public static void main(String[] args)

  {

      max_cards=45;

      arr->new ArraryList

      col=1;

      card=0;

      left=max_cards;

      do{

          col->random number

          row->new ArrayList;

          for i=0 to i<col

          {

              card++

              add card into row

          }

          add row into arr

          left=max_cards-card;

      }while(card<max_cards);

      finish->false

      while(!finish)

      {

          for i=0 to arr.size()

              remove one card from each row

          add row into arr

          size->new ArrayList;

          for i=0 to i<arr.size()

              add arr[i] into size

          sort(size)

          for i=1 to size.size()

              if ith element is equals to (i-1)+1

                  finish->true

              else

                  finish->false

          for i=0 to i<arr.size()

              print->arr elements

      }

  }

}

You might be interested in
Your school has been declared a school of technology
Angelina_Jolie [31]
I don't really understand the meaning of the question. Can you reply and i'll try to help...
7 0
3 years ago
If you are uploading files you plan to edit online, you will need to convert them to Google Drive format. T or F
Amiraneli [1.4K]

Answer:

save as a word document (.docx) to keep editing offline then copy and paste into the google doc

5 0
3 years ago
Easy way of communication with people is one disadvantage of a network. *<br><br> 1.True<br> 2.False
Maksim231197 [3]

Answer:

false

because we are able to connect with people easily..

without have to wait for long time in the case of letters..

4 0
2 years ago
Read 2 more answers
Which of the following resources is an example of a web-based application?
kompoz [17]
The answer will be google docs since it depends on a web and its an application. hope it helps

3 0
3 years ago
Which of the following best describes the safety of blogging
Pavlova-9 [17]
We need the options
3 0
3 years ago
Other questions:
  • What is basic function of an operating system?
    10·2 answers
  • How do media and networks interact
    11·1 answer
  • You can access various sites on the WWW by using hyperlinks or by______. A. entering a key word for your search B. following dir
    12·2 answers
  • SHOW ALL YOUR WORK. REMEMBER THAT PROGRAM SEGMENTS ARE TO BE WRITTEN IN JAVA. Assume that the classes listed in the Java Quick R
    9·1 answer
  • How many ways do advertisers determine target audiences ??????
    15·1 answer
  • What is presentation
    15·2 answers
  • Open the NetBeans IDE and create a new project named MySizes.java. Your program should do the following:
    9·1 answer
  • The =COUNT function calculates what value?
    15·2 answers
  • The success criteria are used to judge whether a project is successful. False True <br> need it now
    13·2 answers
  • Guys, please help me asap (Photo Attached) !!!!!!! HELP 25pts!!!!
    14·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!