Search:

Type: Posts; User: mjballa

Search: Search took 0.39 seconds.

  1. Replies
    2
    Views
    1,314

    Can I do this with methods in Java?

    I need to run a method 4 times and store the data gained somewhere so I can display it later.
    is this statement correct? if not is there any way to do this?
    public void myMethod()
    {
    //stuff in...
  2. Replies
    1
    Views
    1,439

    Using arrays more efficiently in Java?

    if I needed to run a program 4 times and wanted to store each of the values I got through previous runs of the program to arrays, would I need to make 4 different arrays or is there another way of...
  3. Replies
    2
    Views
    1,228

    Re: How do I display the contents of this array?

    Nevermind I got it!
  4. Replies
    2
    Views
    1,228

    How do I display the contents of this array?

    This might be a stupid question to some people. Sadly I am a rookie programmer. This is my task: Display the contents of the array by using a
    method that receives the array as a parameter and uses...
  5. How do I sort strings without using the sort method?

    public static void idNumberSort(String[] array)
    {
    int startScan, index, maxIndex, maxValue;

    for (startScan = 0; startScan < (array.length-1); startScan++)
    {
    maxIndex = startScan;...
  6. Replies
    8
    Views
    1,626

    Re: What's wrong with my code?

    import java.util.Scanner;

    public class Lab8_Ex2
    {
    public static void main(String[] args)
    {
    int age;
    int beatsPerMinute;
    boolean heartRate;
  7. Replies
    8
    Views
    1,626

    Re: What's wrong with my code?

    Lab8_Ex2.java:22: cannot find symbol
    symbol : variable heartRate
    location: class Lab8_Ex2
    targetHeartRate(heartRate);
    ^


    Lab8_Ex2.java:24: cannot find symbol
    symbol :...
  8. Replies
    8
    Views
    1,626

    Re: What's wrong with my code?

    sorry I pasted it wrong. here it is!





    import java.util.Scanner;

    public class Lab8_Ex2
    {
  9. Replies
    8
    Views
    1,626

    What's wrong with my code?

    import java.util.Scanner;

    public class Lab8_Ex2
    {
    public static void main(String[] args)
    {
    int age;
    int beatsPerMinute;
  10. Replies
    2
    Views
    1,299

    Re: How would I write this program?

    thanks for the advice, I'll keep this in mind while constructing my pseudocode.
  11. Replies
    4
    Views
    1,368

    Re: How do I fix my program?

    thanks for the replies.
    it does compile however it does not do much if anything like you said.

    yeah that's pretty much the goal of this program. I just have to count the number of instances that...
  12. Replies
    4
    Views
    1,368

    How do I fix my program?

    /*This program will allow the user to search for a particular
    file he/she desires and count the number of times a particular
    substring occurs in the file.
    */

    import java.util.Scanner;...
  13. Replies
    2
    Views
    1,299

    How would I write this program?

    I have this programming assignment which calls for:
    1) The user to enter a file to use.
    2) Then the user enters a particular sub string to search for.
    3) The object of the program would be count...
Results 1 to 13 of 13