Do { .. } while(..) or while () { .. } ??

Hello,
I think the only one difference between :
do {
} while (...);and
while(..) { .. } In do while: the body wil be excuted at least once but that is not the case in while ..!! Is this true?
In which cases (situations or problems) you should choose for do {}while() ?
Thank you

Rkas wrote:
jverd wrote:
Rkas wrote:
I read:
The difference between do-while and while is that do-while evaluates its expression at the bottom of the loop instead of the top. Therefore, the statements within the do block are always executed at least once, as shown in the following DoWhileDemo program:
That is what I said too!So, your initial question was to ask "Here is what the tutorial says. Is it right"?hahaha, no, that's not the question !! :-D
Look, I am looking for some example (not theory) for using do while! practice examples. :)
Thanksdo
System.out.println("press 1 to widraw money");
System.out.println("press 2 to check balance");
System.out.println("press 5 to exit");
System.out.println("select your option");
//get input and call function accordingly
}while(option!=5)
you can think about it as ATM screen
It is necessary to show you the screen at least one time
even if you want to exit in the first attempt itself.

Similar Messages

  • My phone gets heat like ****, while charging, while using attending a call and playing games

    my phone gets heat like ****, while charging, while using attending a call and playing games, can some one help me out of this?

    Basics from the User Guide are restart, reset, restore.  Try each of these.  If they don't work, bring your phone into Apple for evaluation.

  • While/Do While

    Is there a general "formula" to transform a while loop into a do-while loop and vice-versa?
    Thank You

    I beleive its like this.....
    do
    // do your stuff
    while //this condition is true
    then while is
    while//this condition is true
    //do your stuff
    Or vice-vercy I can't remember right now

  • Getting data from a while loop while running.

    Hello,
    I did a program that call a sub-VI which is doing experiment and have its own timer.
    The sub-VI is a while loop and the stop condition of this loop is the elapsed time of my timer.
    What I want to do is to be able to get the elapsed time in my main program during the execution of the sub-VI (every second of its execution).
    First I assign the elapsed time in the sub-VI as an output of it. But of course the elapsed time is only updated in the main VI only when the while loop has finished. So I tried several solution: property nodes, local variable, global variable.
    When I am using global variable, I can see the elapsed time being updated during the while loop when I open the global variable VI. But the result is always the same: in the main VI the elapsed time is only updated at the end of the while loop.
    I think that is the global variable is updated every time, I could be able to get its data to my main VI?
    Does anyone have an idea?
    Thank you,
    Meach

    I tried using shared variable and reference without succes.
    I will keep searching.
    I enclose my VI that I simplify the most but with still keeping the shape of my real program. If you can take a look I will really appreciate.
    The goal is on the top-level VI to be able to see the updating data time in real time.
    Thanks,
    Meach
    Message Edited by Meach on 07-23-2008 04:13 PM
    Message Edited by Meach on 07-23-2008 04:14 PM
    Attachments:
    Elapsed Time.zip ‏25 KB

  • Validation of LOVs in Timecard while update/while trying to view details

    Dear gurus of OTL,
    I have followed this forum a lot while implementing OTL for a project and gained lots of interesting things.I have come across another interesting scenario .I have 3 LOVs in my timecard which are based on 3 xml queries.I fill out a timecard with 3 values in these lovs,i submit it and get it approved.After few days for audit purpose we check the approved timecards by clicking on the details of a timecard.Amazingly the 3 values i have entered once again get validated against the 3 xml queries and if it doesn't meet the criteria i see null there.How reasonable is this validation?
    Another observation is when we enter a timecard and save it and defer submission to a later time seeing more changes.we then try to update them and it does it again the previoulsy entered lines in the timesheet get validated against the xml queries which is a Performance issue in this case.Let me know your insights on this.
    Thanks & Regards,
    Sameer.T

    It might be something to do with the way the field is defined in the LDT file which defines the timecard layout.
    On a data entry timecard, the LOV is based on a ViewObject which in turn is a view which retireves the data from its source (a value set or some other table(s) on the database). The VO usualy returns two columns, the display value and the id of the record. The user selects the value from the display list, and then OTL stores the id of the record on the datbase.
    When the system retrieves the data to display, for example in your details page, it must read the id of the stored record and convert it back to the display value. Perhaps the VO associated to this process is not accounting for end dated projects?
    Regards
    Tim

  • Error while printing (while saving?)

    Whenever I try to save my book I always get the error:
    Print
    Error while printing.
    However, I'm not trying to print, I'm trying to SAVE.  From what I can tell the file is saving just fine, however I hope that there is nothing actually wrong with the file for when I go to hit "publish"
    Anybody else run into this and solve it?  Should I worry?

    Maybe there is an extension or OS widget that's acting up...
    'save' is for an .iba file - 'publish' is for an .ibooks file. I don't think you'll have issues, but you'll know when you try

  • Won't boot from DiskWarrior CD while starting while pressing "c" key

    Hello,
    I am helping a friend maintain her 2008 MacBook Pro (10.5.8). Have safe-booted several times, and repaired permissions.
    Since she is having minor issues, I brought over my Disk Warrior v. 4.1 (CD rev. 42) which has done wonders for other Leopard Macs.
    Her MacBook Pro just refuses to boot from the Disk Warrior CD when I hold down the "c" key while re-starting. It starts as usual from its OS. This has never happened to me before. So I cannot use Disk Warrior on her comp, as far as I know.
    Whenever I have used this Disk Warrior CD on mine and other 10.5.8 computers, and booted holding down "c" key, everything goes swimmingly.
    Grateful if anyone can anyone offer a suggestion...
    Could it be her drive, her logic board, my not re-setting PRAM on her computer? Or a total mystery?
    Many thanks,
    Neil

    You need version 4.1.1

  • Help learning while/do while loops

    Hi everyone, glad to see there are resources out here like this where newbies with Java can get help and learn from the gurues!
    I am having a problem with constructing a while loop that is going to compute the sinx without using the Math.sin function....so given this
    sinx = x - (x^3/3!) + (x^5/5!) - (x^7/7!) + ......
    It seems I need to use the Math.pow function. So the sinx is alternating signs between each new set of parenthesis and the power and factorial are increasing by 2..starting with 3. I think this is were I am having my trouble.
    I was going to use a do-while loop for cosx which is
    cosx = x - (x^2/2!) + (x^4/4!) - (x^6/6!) + ......
    I think my problem is that I can't figure out how I would go about writing this. If I can get the sinx with the while loop, I can probably get the cos on a do-while statement since they are similar. I did get factorial(n) defined below.
    I have another main class which I am using to get the input of sin/cos x using computeSin and computeCos functions I am trying to build here.
    import javax.swing.*;
    public class NewMath
    public static double computeSin(double x)
    double result = x;
              // Going to use A WHILE LOOP
    return result;
         public static double computeCos(double x)
    double result = 1;
              // Going to use a DO-WHILE loop
    return result;
    private double factorial(int x) {
    if (x <= 1) return 1.0;
    else return x * factorial(x - 1);
    Any tibits of help would be nice. If I think I got it working before someone else posts, I'll post my results. Thanks.

    Any tibits of help would be nice. If I think I got
    it working before someone else posts, I'll post my
    results. Thanks.You already have your own tidbits, as you've observed the pattern of alternating adding/subtracting, as well as how the power and factorial factors relate. Any more "tidbits" here would just result in doing it for you, it seems. So get to it, and if you run into specific problems, you can ask.

  • Starting new while loop while old one still running

    Hi!
    I am attempting to write video images to AVI files. I want to give the user the option to decide when they want to begin to capture the images. I place the "start recording" button in one loop and the image acquisition and AVI Write subVIs in another loop. LabVIEW won't allow me to continue on with the image acquisition loop until I finish with the "start recording" loop. Any ideas how to fix this (to allow the image acquisition to start and continue having LabVIEW check for a button press on "start recording")?
    Attachments:
    Capture_and_Save_as_AVI.vi ‏177 KB

    Thanks. I suspected as much. In any event, I can't seem to find a good configuration of while loops and case structures which will produce the desired results. I want to start acquiring images and allow the user to choose to start recording at any time he desires. This issue is further complicated by the fact that the status of the "Start recording" must be checked at all times, but only initialized once, while the AVI Write Frame depends on that first initialization step but must be looped continuously aferwards in order to 'keep up' with the images being acquired. In the newly attached example, I placed the case structure inside the image acquisition while loop and the avi write frame inside a while loop inside of that case structure. unfortunately,
    labview decides to stay inside the avi write frame while loop after entering, instead of returning to the image acquisition while loop. i can't place the avi write frame inside the general image acquisition while loop because then labview will think i want to initialize the avi write frame right away and will return an error when avi write frame isn't provided with an avi refnum. Ideas?
    Attachments:
    Capture_and_Save_as_AVI.vi ‏174 KB

  • Programming a times table with FOR, WHILE & DO WHILE STATEMENTS

    Guys,
    Help me, I have tried hard, but I didn't find the answer, my problem is that I got difficulties in doing a times table with the FOR, WHILE, and DO WHILE STATEMENTS just using a single index or a single variable.
    Guys, is it possible to program a times table with these conditions all together in the same code???
    Do I await your suggestions?
    Ps: Below, the attempt that I did, but I was not successful.
    import javax.swing.JOptionPane;
    public class tab
    public static void main(String args[])
    int i;
    String TimesTable= "";
    int result=0;
    do
    for (i=0;i<=10;i++)
    result=i*1;
    TimesTable +="\n" + i + "x" + i + "=" + result;
    //JOptionPane.showMessageDialog(null, "Times tables of " + i + TimesTable);
    // TimeTable="";
    // i=0;
    // i=i+1;
    // i=0;
    while(i<=10)
    i=i+1;
    // System.out.println("2 x "+i+"="+2*i);
    // i--;
    }while(i!=0);
    JOptionPane.showMessageDialog(null, "Times Table of " + i + TimesTable);
    TimesTable="";
    }

    You can use the if block "if(i%10==9)" in this case.

  • Lumia920 losing battery while charging (while usin...

    As title, I have turned off all background applications, 3G, and put phone into battery saver mode. The phone was charging with USB power and only serve as a GPS in my car running Nokia Drive. And I found the power was dropped by 20%in within two hours. This is unacceptable.

    Using nokia drive or any maps is a high battery consumer and charging via usb in car does not provide as much power as per home charging from wall.
    If  i have helped at all a click on the white star below would be nice thanks.
    Now using the Lumia 1520

  • For,while,do-while

    can anyone hekp me how to prints numbers 10 through 99 in the following format:
    10 11 12 13 14 15 16 17 18 19
    20 21 22 23 24 25 26 27 28 29
    and so on...plese bear with me i am a new user of this stuff..thaks alot

    You can use the if block "if(i%10==9)" in this case.

  • Error while Test Connection with Connector

    hi all:
         there is an error while  Test Connection with Connector , I also test it through sys administration->sys configuration->
    suport -> sap transaction, I got all errors, I put these two errors as folows, could you please tell me how to sovle it
    ***************ERROR 1 while *error while Test Connection with Connector ******************************************************
    Test Details:
    The test consists of the following steps:
    1. Retrieve the default alias of the system
    2. Check the connection to the backend application using the connector defined in this
    system object
      Results
    Retrieval of default alias successful
    Connection failed. Make sure that Single Sign-On is configured correctly
    ************error sys administration->sys configuration-> suport -> sap transaction        ********************** 1.5 #0025B3E02892006100000A0800001798000487530FB0122E#1274690722265#com.sap.portal.prt.runtime#sap.com/irj#com.sap.portal.prt
    .runtime#guodongdong#47472##n/a##690347f0670e11df98cc0025b3e02892#SAPEngine_Application_Thread[impl:3]
    9##0#0#Error##Java###04:4524/05/10_0077_6087550
    [EXCEPTION]
    #1#com.sapportals.portal.prt.runtime.PortalRuntimeException: Exception in SAP Application Integrator occured: Application URL
    &\#39;:///sap(ZT1KVXBWektldldTeV9QQXBXRjNaWTRBLS1OZmRvZzBRWWY2QmN0WThNUmgqdUlRLS0=)/bc/gui/sap/its/webgui&\#39; is not valid!
    Please check the protocol and host entries for system &\#39;sapdev&\#39;.
         at com.sapportals.portal.appintegrator.AbstractIntegratorComponent.doContentPass
    (AbstractIntegratorComponent.java:123)
         at com.sapportals.portal.appintegrator.AbstractIntegratorComponent.doContent(AbstractIntegratorComponent.java:98)
         at com.sapportals.portal.prt.component.AbstractPortalComponent.serviceDeprecated(AbstractPortalComponent.java:209)
         at com.sapportals.portal.prt.component.AbstractPortalComponent.service(AbstractPortalComponent.java:114)
         at com.sapportals.portal.prt.core.PortalRequestManager.callPortalComponent(PortalRequestManager.java:328)
         at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:136)
         at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:189)
         at com.sapportals.portal.prt.component.PortalComponentResponse.include(PortalComponentResponse.java:215)
         at com.sapportals.portal.prt.pom.PortalNode.service(PortalNode.java:645)
         at com.sapportals.portal.prt.core.PortalRequestManager.callPortalComponent(PortalRequestManager.java:328)
         at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:136)
         at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:189)
         at com.sapportals.portal.prt.core.PortalRequestManager.runRequestCycle(PortalRequestManager.java:753)
         at com.sapportals.portal.prt.connection.ServletConnection.handleRequest(ServletConnection.java:240)
         at com.sapportals.portal.prt.dispatcher.Dispatcher$doService.run(Dispatcher.java:523)
         at java.security.AccessController.doPrivileged(Native Method)
         at com.sapportals.portal.prt.dispatcher.Dispatcher.service(Dispatcher.java:412)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
         at com.sap.engine.services.servlets_jsp.server.servlet.InvokerServlet.service(InvokerServlet.java:156)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
         at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.runServlet(HttpHandlerImpl.java:401)
         at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.handleRequest(HttpHandlerImpl.java:266)
         at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:386)
         at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:364)
         at com.sap.engine.services.httpserver.server.RequestAnalizer.invokeWebContainer(RequestAnalizer.java:1039)
         at com.sap.engine.services.httpserver.server.RequestAnalizer.handle(RequestAnalizer.java:265)
         at com.sap.engine.services.httpserver.server.Client.handle(Client.java:95)
         at com.sap.engine.services.httpserver.server.Processor.request(Processor.java:175)
         at com.sap.engine.core.service630.context.cluster.session.ApplicationSessionMessageListener.process
    (ApplicationSessionMessageListener.java:33)
         at com.sap.engine.core.cluster.impl6.session.MessageRunner.run(MessageRunner.java:41)
         at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37)
         at java.security.AccessController.doPrivileged(Native Method)
         at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:104)
         at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:176)

    Hi,
    As per this part of the trace:
    Exception in SAP Application Integrator occured: Application URL &\#39;:///sap(ZT1KVXBWektldldTeV9QQXBXRjNaWTRBLS1OZmRvZzBRWWY2QmN0WThNUmgqdUlRLS0=)/bc/gui/sap/its/webgui&\#39; is not valid! Please check the protocol and host entries for system &\#39;sapdev&\#39;. at ...
    You can clearly see that the system object 'sapdev' is not configured correctly/at all - you are trying to launch transaction iView
    (WEBGUI) and in order to do so you should configure the 'internet transaction server' category of the system  object
    with the hostname of the ITS server.
    Generally the template is
    <System.Access.ITS.protocol>://<System.Access.ITS.hostname>/sap<ESID>/bc/gui/sap/its/webgui?\....
    So that's why you got
    Please check the protocol and host entries for system ..

  • Schema Data Type in SOAP Web Service while using Integration Gateway in SMP 3.0

    Hi Experts,
    I was working on Integration gateway component of SMP 3.0.3 where we can have oData services which connect to different data source from SMP and finally we have to consume from SMP. Here I have an SOAP Web service where there is Schema Data type which is an xml structure and because of that while doing the data modelling with Design time tools I am not able to map the properties as there aren't any as only the parent level Schema type is available in the SOAP Web Services. Please see the below image for reference :
    So now I have 2 inputs no problems for design as such then I have the schema for that which comes as a output response which is where I am facing the issue as we don't have that Data Structure itself so how are we going to map that. I have seen some thin possibilities with Custom Scripts with SMP SP06 where this will help us to process the request and response at runtime with JS/Groovy. So needed some lights on this schema data type on Integration Gateway component of SMP 3.0.3 which we are planning to upgrade to SP06 as well so it will be a good starting point for this as well
    Also have concerned my good friend Rakshit Doshi for this as well.
    Regards,
    Fenil.

    Hi All,
    Sorry for the late response guys was stuck somewhere else and so couldn't reply to this, see I have below response in SOAP UI
    There if we see we have the schema as the whole structure being defined under which we have all the child elements, am also posting the raw response from the soapUI below for better understanding
    <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
       <soap:Body>
          <GetMSUserLoginDetailsResponse xmlns="http://tempuri.org/">
             <GetMSUserLoginDetailsResult>
                <xs:schema id="MemberDetails" xmlns="" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
                   <xs:element name="MemberDetails" msdata:IsDataSet="true" msdata:UseCurrentLocale="true">
                      <xs:complexType>
                         <xs:choice minOccurs="0" maxOccurs="unbounded">
                            <xs:element name="Table">
                               <xs:complexType>
                                  <xs:sequence>
                                     <xs:element name="RECID" type="xs:string" minOccurs="0"/>
                                     <xs:element name="FNAME" type="xs:string" minOccurs="0"/>
                                     <xs:element name="LNAME" type="xs:string" minOccurs="0"/>
                                     <xs:element name="CUSTNO" type="xs:decimal" minOccurs="0"/>
                                     <xs:element name="MEMTYP" type="xs:decimal" minOccurs="0"/>
                                     <xs:element name="MEMTYPENAME" type="xs:string" minOccurs="0"/>
                                     <xs:element name="CUSTTYP" type="xs:decimal" minOccurs="0"/>
                                     <xs:element name="EMAIL" type="xs:string" minOccurs="0"/>
                                     <xs:element name="MEMPASSWORD" type="xs:string" minOccurs="0"/>
                                     <xs:element name="ISDEBIT" type="xs:decimal" minOccurs="0"/>
                                     <xs:element name="PARENTID" type="xs:string" minOccurs="0"/>
                                     <xs:element name="CHILDOF" type="xs:string" minOccurs="0"/>
                                     <xs:element name="CUSTTYP1" type="xs:string" minOccurs="0"/>
                                     <xs:element name="ZONEID" type="xs:int" minOccurs="0"/>
                                     <xs:element name="EMAILFOOTERDETAIL" type="xs:string" minOccurs="0"/>
                                  </xs:sequence>
                               </xs:complexType>
                            </xs:element>
                            <xs:element name="Table1">
                               <xs:complexType>
                                  <xs:sequence>
                                     <xs:element name="ErrorCode" type="xs:string" minOccurs="0"/>
                                     <xs:element name="ErrorDesc" type="xs:string" minOccurs="0"/>
                                  </xs:sequence>
                               </xs:complexType>
                            </xs:element>
                         </xs:choice>
                      </xs:complexType>
                   </xs:element>
                </xs:schema>
                <diffgr:diffgram xmlns:msdata="urn:schemas-microsoft-com:xml-msdata" xmlns:diffgr="urn:schemas-microsoft-com:xml-diffgram-v1">
                   <MemberDetails xmlns="">
                      <Table diffgr:id="Table1" msdata:rowOrder="0">
                         <RECID>97101-101-0000057069</RECID>
                         <FNAME>Fenil</FNAME>
                         <LNAME>Doshi</LNAME>
                         <CUSTNO>1042231</CUSTNO>
                         <MEMTYP>42</MEMTYP>
                         <MEMTYPENAME>Management</MEMTYPENAME>
                         <CUSTTYP>8</CUSTTYP>
                         <EMAIL>[email protected]</EMAIL>
                         <MEMPASSWORD>as</MEMPASSWORD>
                         <PARENTID>97101-101-0000057069</PARENTID>
                         <CUSTTYP1>Zone</CUSTTYP1>
                         <ZONEID>2</ZONEID>
                         <EMAILFOOTERDETAIL><![CDATA[<strong></strong><br />]]></EMAILFOOTERDETAIL>
                      </Table>
                      <Table1 diffgr:id="Table11" msdata:rowOrder="0">
                         <ErrorCode>100</ErrorCode>
                         <ErrorDesc>Login Successful.</ErrorDesc>
                      </Table1>
                   </MemberDetails>
                </diffgr:diffgram>
             </GetMSUserLoginDetailsResult>
          </GetMSUserLoginDetailsResponse>
       </soap:Body>
    </soap:Envelope>
    So we have the data but as a xml Structure which is nothing but schema and is my Eclipse while mapping while defining response type it gives me just an schema as the property.
    Regards,
    Fenil.

  • How can I allow a sub-vi to run independent of the main program once it has been called while still sending data to the sub-vi

    I have a main program where I call a sub-vi. In this sub-vi, there is a while loop that is used to wait for commands in the sub-vi. While the while loop is running, I cannot continue with normal operation of the main program. I would like get the sub-vi to run independently once it has been called, but not hold up the main program. As well, I need to still be able to send data to the sub-vi

    One way is to use VI Server, which has been mentioned by others. This will allow you to start another VI (by name) and run it entirely independently of the calling VI. This is a good way to start various independent VIs from a main menu, for example. None of the VIs thus called need have any connection to the others.
    Another way it to have the SubVI in a separate while loop on the calling VI's BD. Then, use a local var to start this sub VI from the main loop. The calling VI sets a local START bit and continues running. The sub VI's while loop watches for this START bit to go true, and then runs the Sub VI. The advantage here is that one can more easily pass arguments to the SubVI when it is started, using local vars, which are preferable to globals. Once the Su
    bVI is running, however, you must use a global Stop Bit, set in the calling VI, to stop it when the calling VI exits, or the calling VI will hang up, waiting for the Sub VI to close and exit its while loop.
    If you need an example of this, email me. ([email protected]). I can also recommend Gary W. Johnson's excellent book which discusses this. ("LabVIEW Graphical Programming", 2nd Ed).
    Note: Where possible, I try to call a subvi from within the main VI, wait till it is done, then continue. It avoids the use of locals & globals, and results in cleaner code, with fewer "race" conditions. However, the main VI stops until the subVI is done, hence one should make the subVI modal.

  • WHILE loop is incorrect

    I have a WHILE statement : "while (s2.substring(k, l) != "<")" that does not work at the bottom of this program. The condition never stops the loop. The JDB does not find any of the fields e. g. PRINT S2
    I am doing this in win XP in a DOS window. My CLASSPATH keeps going away for some reason. I set it as CLASSPATH=.;d:\program files\java\jre1.5.0_11\lib\ext\qtjava.zip;c:\program files\java2\java\jdk1.5.0_11
    At one time JDB worked with this program. For some reason, now it does not. But the WHILE condition has never worked.
    import java.util.*;
    import java.io.*;
    public class readfile4
    public static void main(String args[])
    // Here we get a list of all files in the current directory
    String list[] = new File(".").list();
    for (int i = 0; i < list.length; i++)
    // Here we take each file name and read all of its
    // records into an array. At this point, we can
    // determine the file size since all the rcds are
    // in an array.
    // If the file size is greater than the original file size
    // then it has been updated, so we look at record 4 and get
    // the name and display it to a screen.
    String s = list.substring(0, 06) ;
    int orgsize = 13000 ;
    if (s.equals("whats_"))
    final int assumedLineLength = 50;
    File file = new File(list[i]);
    List<String> fileList =
    new ArrayList<String>((int)(file.length() / assumedLineLength) * 2);
    BufferedReader reader = null;
    int lineCount = 0;
    try {
    reader = new BufferedReader(new FileReader(file));
    for (String line = reader.readLine(); line != null;
    line = reader.readLine()) {
    fileList.add(line);
    lineCount++;
    } catch (IOException e) {
    System.err.format("Could not read %s: %s%n", file, e);
    System.exit(1);
    } finally {
    if (reader != null) {
    try {
    reader.close();
    } catch (IOException e) {}
    // At this point we have the the entire file in an array.
    // The above loop has put all the records for the "i" file
    // in an array.
    // Now, if the filename is "whats_new_....." then extract
    // the classmates name out of the 4th record and display it.
    // Then return for the next record from the directory list.
    String s2 = fileList.get(3) ;
    String s2a = s2.substring(0, 5);
    String s3 = " " ;
    // Only look at title records to get the name
    // because some of the html records are
    if (s2a.equals("<titl"))
    int k = 7 ;
    int l = k + 1 ;
    while (s2.substring(k, l) != "<")
    k++ ;
    l++ ;
    s3 = s2.substring(7, l) ;
    else
    s3 = " " ;
    if (file.length() > orgsize)
    System.out.println(s3 + " - has updated their bio ") ;

    That condition may very well never be met. Using logical operators (==, !=, etc) to compare strings is a bad idea. Strings are objects, you should compare them with the equals() method.
    try
    while (!s2.substring(k, l).equals("<")) {
    //etc
    }

Maybe you are looking for