Operations on stack

Hi guys,
I've got a simple stack working, but am having some problems with the input commands. Basically, the commands "empty", "pop", and "peek" are only meant to operate on the stack, not to be inserted inside it. They function on it and also operate on it. Any suggestions how this can be fixed? I don't want them to be inserted into my stack, just to operate.
Heres my code:
// Code By SSPanesar, 2006
// this code was made using Java API
import java.util.*;
import java.io.*;
public class Stacks2
public Stacks2()
         Stack pile = new Stack(); // making a new instance Stack
        String s = "";
        boolean truth = false;
        int check = 0; // used as a counter
        BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
        System.out.println("Please enter some text, and finish with 'end'");
        while (truth == false)
          try
             s = in.readLine();
          catch(IOException e)
            if(s.equals("end")) // what to enter to end program
                      truth = true;
                if(s.equals("pop"))
                   if(check==1)
                     System.out.println("stack empty");
                     // truth = true; THIS IS INSERTED HERE TO END THE PROGRAM WHEN THE STACK IS EMPTY (OPTIONAL)
                   else
                         check = check - 1;
                         System.out.println("The value: "+pile.pop()+" has been removed from the stack");
                         System.out.println("The size of the Stack is: "+check);
            if(s.equals("peek")) // reading top value of the program
                    System.out.println("The top value in the stack is: "+pile.peek());
          else
            pile.push(s);
            check = check + 1;
            System.out.println("You Just entered into the Stack :"+s);
          for(int a=0;a<check;a++)
            System.out.println(pile.pop());
        public static void main(String[] args)
           Stacks2 box = new Stacks2();
}

ok, so with the code that I have here, is there no
alteration that can be done to solve this problem?First, you haven't really defined what the problem is, aside from saying that you don't want to define methods like pop() and push() in your Stack class. That doesn't make any sense, and I've pointed you to some resources that tell you why.
Second, I haven't bothered to dissect your code because it's a bit tough to look at. I recommend that for now, you strictly adhere to the standard Code Conventions for the Java� Programming Language. It will make your code much easier to read, which of course, makes it much more likely you'll get others to look at it.
Third, don't flag your question as urgent, even if it is for you.
* We all answer questions here voluntarily, in our leisure time. We do that because doing so is fun for us, because we enjoy helping people and having interesting discussions. Guess what, it is much less fun if it gets stressful. So the last thing you want to do to get us to answer your question is to pass your stress over to us.
* People who are stressed and want a fast answer often don't even find the time to do the necessary research or to formulate their question in an easy to comprehend way. That's even less fun to work with. So you really don't want us to feel your stress. Instead you want to take your time to write a well formulated post that is fun to answer. The less likely it is for us to know that your question is urgent, the more likely you are to get a fast answer!
* The simple notion that you want your post to be answered faster than those of the other members might feel rather unfair to some of us. Doubly so because often "urgent" questions actually are homework questions. Yours might be different, but someone who had bad experiences with this type of question might not read far enough to notice.
So, yes, there is alteration that can (and should be done). Read those links, and research existing example Stack code. There are scads of examples out on the web, and will be easy to find. If you have a specific coding error that you're having trouble working out, make sure you describe the problem specifically.
Good luck!

Similar Messages

  • SG500 and native stacking doubt.

    Hello,
    I have 8 sg500 in native stacking using optical fiber:
    Operational Status
    Stack Mode: Native Stacking
    Stack Topology: Ring
    System Mode: L3
    Stack Master: Unit 1
    Master Election Status: Automatic Master Election
    Administrative Status
    System Mode L3 Mode
    Queues Mode 4 Queues
    Stack Administrative Settings Table
    1 SG500-52 S3 1G Unit3 S4 1G Unit2
    2 SG500-28 S3 1G Unit1 S4 1G Unit8
    3 SG500-52 S3 1G Unit4 S4 1G Unit1
    4 SG500-28 S3 1G Unit3 S4 1G Unit5
    5 SG500-28 S3 1G Unit6 S4 1G Unit4
    6 SG500-52 S3 1G Unit5 S4 1G Unit7
    7 SG500-52 S3 1G Unit6 S4 1G Unit8
    8 SG500-28 S3 1G Unit7 S4 1G Unit2
    But, fiber connection between 6 and 7 is in standby ( led not blibking, green all time ).
    is this normal behaviour???
    Why does work like others fiber connections?
    best regards.

    Software Information
    Firmware Version (Active Image): 1.3.7.18
    Firmware MD5 Checksum (Active Image): 595c976a2f097c197111df59cec078d9
    Firmware Version (Non-active): 1.3.7.18
    Firmware MD5 Checksum (Non-active): 595c976a2f097c197111df59cec078d9
    Boot Version: 1.3.7.01
    Boot MD5 Checksum: 0ac608b735909d9d101399216c4eab22
    Locale: en-US
    Language Version: 1.3.7.18
    Language MD5 Checksum: N/A

  • I need help installing SQL Server 2012 Express

    I am very much an amateur. I got a new machine. The old one had Server 2008 R2 but the recommendation was that I need to move to 2012 Express.
    When I moved to the new machine, the mover (LapLink) screwed up the version of 2008 R2. IOW, I now have to go forward and install 2012..
    I downloaded all the 64 bit files (5 of them). When I start SQLEXPR_x64_ENU.exe, the process starts and then I'm given the choice of a new install or upgrade. I chose the new install. The process started and I got the following message ...
    "Failed to retrieve data for this request.."
    There are no hints anyplace as to what this means.
    When I click "OK", a new status window pops up and proclaims that something is wrong. Then all activity stops.
    I don't know what to do. I can't use either version and I really can't tell you much more to help me.
    Eric Johnson

    I'm not certain how to send the log material so I'll just cut 'n paste the file named "Summary_Eric-PC_20140921_134001_GlobalRules" If this isn't the right way, please forgive me and suggest what is right. Anyway, here goes ...
    Overall summary:
      Final result:                  Failed: see details below
      Exit code (Decimal):           -2146233088
      Exit facility code:            19
      Exit error code:               5376
      Exit message:                  Failed to retrieve data for this request.
      Start time:                    2014-09-21 13:40:09
      End time:                      2014-09-21 13:40:29
      Requested action:              RunRules
      Exception help link:           http://go.microsoft.com/fwlink?LinkId=20476&ProdName=Microsoft+SQL+Server&EvtSrc=setup.rll&EvtID=50000&ProdVer=11.0.2100.60&EvtType=0x48BB60BC%400xBB814387&EvtType=0x48BB60BC%400xBB814387
    Machine Properties:
      Machine name:                  ERIC-PC
      Machine processor count:       8
      OS version:                    Windows 7
      OS service pack:               Service Pack 1
      OS region:                     United States
      OS language:                   English (United States)
      OS architecture:               x64
      Process architecture:          64 Bit
      OS clustered:                  No
    Package properties:
      Description:                   Microsoft SQL Server 2012
      ProductName:                   SQL Server 2012
      Type:                          RTM
      Version:                       11
      SPLevel:                       0
      Installation location:         c:\851594228c4871a4e88415938631\x64\setup\
      Installation edition:          Express
    User Input Settings:
      ACTION:                        RunRules
      CONFIGURATIONFILE:             
      ENU:                           true
      FEATURES:                      
      HELP:                          false
      INDICATEPROGRESS:              false
      INSTANCENAME:                  <empty>
      PID:                           *****
      QUIET:                         false
      QUIETSIMPLE:                   false
      RULES:                         GlobalRules
      UIMODE:                        AutoAdvance
      X86:                           false
      Configuration file:            C:\Program Files\Microsoft SQL Server\110\Setup Bootstrap\Log\20140921_134001\ConfigurationFile.ini
    Rules with failures:
    Global rules:
    There are no scenario-specific rules.
    Rules report file:               The rule result report file is not available.
    Exception summary:
    The following is an exception stack listing the exceptions in outermost to innermost order
    Inner exceptions are being indented
    Exception type: Microsoft.SqlServer.Management.Sdk.Sfc.EnumeratorException
        Message:
            Failed to retrieve data for this request.
        Data:
          HelpLink.ProdName = Microsoft SQL Server
          HelpLink.BaseHelpUrl = http://go.microsoft.com/fwlink
          HelpLink.LinkId = 20476
          HelpLink.EvtType = 0x48BB60BC@0xBB814387
          DisableWatson = true
        Stack:
            at Microsoft.SqlServer.Management.Sdk.Sfc.Enumerator.Process(Object connectionInfo, Request request)
            at Microsoft.SqlServer.Chainer.Infrastructure.SqlDiscoveryDatastoreInterface.ProcessDTbl(DataTable dt, Int32 level)
            at Microsoft.SqlServer.Chainer.Infrastructure.SqlDiscoveryDatastoreInterface.ProcessDTbl(DataTable dt, Int32 level)
            at Microsoft.SqlServer.Chainer.Infrastructure.SqlDiscoveryDatastoreInterface.CollectSqlDiscoveryData(String machineName)
            at Microsoft.SqlServer.Chainer.Infrastructure.SqlDiscoveryDatastoreInterface.CollectDiscoveryData(String machineName)
            at Microsoft.SqlServer.Chainer.Infrastructure.SqlDiscoveryDatastoreInterface.LoadData(IEnumerable`1 machineNames, String discoveryDocRootPath, String clusterDiscoveryDocRootPath)
            at Microsoft.SqlServer.Configuration.SetupExtension.RunDiscoveryAction.ExecuteAction(String actionId)
            at Microsoft.SqlServer.Chainer.Infrastructure.Action.Execute(String actionId, TextWriter errorStream)
            at Microsoft.SqlServer.Setup.Chainer.Workflow.ActionInvocation.ExecuteActionHelper(TextWriter statusStream, ISequencedAction actionToRun, ServiceContainer context)
        Inner exception type: Microsoft.SqlServer.Configuration.Sco.ScoException
            Message:
                    Attempted to perform an unauthorized operation.
            HResult : 0x84bb0001
                    FacilityCode : 1211 (4bb)
                    ErrorCode : 1 (0001)
            Data:
              WatsonData = HKEY_LOCAL_MACHINE@SOFTWARE\Microsoft\Microsoft SQL Server\MSSQL10_50.SQLEXPRESS\Setup
            Stack:
                    at Microsoft.SqlServer.Configuration.Sco.InternalRegistryKey.OpenSubKey(String subkey, RegistryAccess requestedAccess)
                    at Microsoft.SqlServer.Configuration.Sco.SqlRegistryKey.OpenSubKey(String subkey, RegistryAccess requestedAccess)
                    at Microsoft.SqlServer.Discovery.DiscoveryUtils.GetLocalMachineSubKey(ServiceContainer ctx, String machineName, RegistryView regView, String regPath, RegistryAccess registryAccess)
                    at Microsoft.SqlServer.Discovery.DiscoveryEnumObject.GetInstanceMapObject(String machineName, RegistryView registryView, String instanceId, String instanceName, String
    instanceType, String instanceSuffix, UpgradedInstanceStateEnum instanceState)
                    at Microsoft.SqlServer.Discovery.DiscoveryEnumObject.GetInstanceMapCollectionInHive(String machineName, RegistryView regView, List`1 subKeys)
                    at Microsoft.SqlServer.Discovery.DiscoveryEnumObject.GetInstanceMapCollection()
                    at Microsoft.SqlServer.Discovery.Instance.GetData(EnumResult erParent)
                    at Microsoft.SqlServer.Management.Sdk.Sfc.Environment.GetData()
                    at Microsoft.SqlServer.Management.Sdk.Sfc.Environment.GetData(Request req, Object ci)
                    at Microsoft.SqlServer.Management.Sdk.Sfc.Enumerator.GetData(Object connectionInfo, Request request)
                    at Microsoft.SqlServer.Management.Sdk.Sfc.Enumerator.Process(Object connectionInfo, Request request)
            Inner exception type: System.UnauthorizedAccessException
                Message:
                            Attempted to perform an unauthorized operation.
                Stack:
                            at Microsoft.SqlServer.Configuration.Sco.InternalRegistryKey.OpenSubKey(String subkey, RegistryAccess requestedAccess)

  • Upgrade to SAP Solution Manager 3.2 to 7.0 EHP

    Dear Experts
    At present I am using SAP Solution manager 3.2. Now I am planing to update SAP Solution Manager 7.0.
    I am some confutation in SAP Solution Manager 7.0 and SAP Solution Manager 7.0 EHP1,
    what i do please help me.
    Regards
    Sanjay C.

    EHP1 is basically a product enhancement of 700 - i.e offers new functionality
    Usually to get to Enhancement packages you need to be operating NW2004S stack based product - in this case 4.0 (now called Solution Manager 7.0)
    I think this proposal will require first an upgrade from 3.2 to 4.0
    then after applying Enhancement Package EHP1 and following pre-reqs for both steps
    Also bearing in mind that Solution Manager is RFC dependant any change in SID, Hostname or client will require
    all RFC connections will need to be adapted
    There may also be special considerations depending on source configuration or the active Solution Manager scenarios and content
    I would take a look at following PDF for reference - it may help in the initial 3.2-->4.0 upgrade
    http://service.sap.com/~form/sapnet?_SHORTKEY=00200797470000090041&_SCENARIO=01100035870000000202&_OBJECT=011000358700000208052007E
    Best wishes
    Stuart

  • Adobe Air Cookies Removed When App Closed?

    Hi,
    I have a flex app which I would also now like to offer an Air client for. I don't want to create a new authentication system just for the Air app, I just want to use the cookie/session setup that I already have in place.
    The cookies work and after logging in to the AIR app I can make subsequent requests without being asked to authenticate again, the problem is that the cookie seems to be deleted when the client is shut down, meaning that when I restart the air client I have to log in again which is obviously not acceptable for my users.
    Is this expected behaviour in AIR and if so, what is the work around?
    Cheers,
    Chris

    Hi Chris,
    AIR uses the underlying operating system stack for managing cookies. As such, cookies can be shared between different AIR applications and with browsers that use OS stack (e.g. Internet Explorer on Windows).
    From the official documentation as well as my experiments, cookies are preserved between application restarts.
    I suspect the application uses session cookies for authentication -- these are meant to be cleared when the browser exits and for a good reason (mostly security). AIR clears session cookies when the application closes, unlike some browsers (e.g. Firefox) that don't always clear them.
    From what I can tell, you have 2 choices here:
    change the authentication system to not use session cookies anymore -- I strongly suggest *NOT* to do this.
    write some code in the application to read/write the credentials from another kind of storage when run in AIR, for instance using the Encrypted Local Store. You could do this by inspecting the value of flash.system.Capabilities.playerType (see http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/flash/system/Capabiliti es.html#playerType ). You would have to write some AIR specific code, but it wouldn't require you to rewrite the authentication system.
    Hope this helps,
    Mihai

  • Folder display and full screen horribly slow?

    I'm currently running on Windows 7, 64 bit.
    I just upgraded from PSE 8 to 10 and had the first run automatically convert my catalog in the organizer. I've turned off all auto-analysis options. Other than being extremely annoyed that I no longer have the option to look at multiple folders at once in folder view -- which is something that almost makes me want to return the software, but it was a gift -- it takes over 30 seconds to switch to or start in folder view, and about the same amount of time to bring up the full screen preview.   Within folder view, switching from "3 stars and higher" back to "show all" takes 35 seconds, and even longer to restrict the view.
    I know it's not my machine; limiting the view to 3 stars in thumbnail view takes less than a second, the same with selecting tags, show all, etc.  It's very snappy.
    In a previous version, Elements 6 I think, I had a strange problem where having the printer set to our regular printer caused an issue like this, and the solution was to set the default to CutePDF printer or something like that. I tried that though and it didn't help. (I'll reboot and try again just in case).
    In PSE 8, it's slow...but not this slow. Plus, I can use it for my main view, since I can see many folders at a time. I won't be able to do that anymore so I have to be able to go back and forth easily.
    Has anyone else experienced this problem?? Any thoughts on what could be causing it?
    Thanks,
    Lisa

    Inexcusable ? You should perhaps rather wonder how it is possible to select a dozen of photos on multiple criteria within seconds. There is no magic there, only the combination of a powerful tool : a relational database, sqlite, and the recording of data from the exif or from your tags. A complex structure and many indexes make this wonder possible. If the data is outside the database and can change... the wonder is no longer there. You are right in your hope of better structure, better indexes, better use of the organizer of the data included in the database.
    Remember I stated earlier that I don't know of a way to do this in my favourite thumbnail view. I think such a feature would be useful when I am using external drives to transfer catalogs and files via backup and restore. Knowing if all pictures are on given disk or if a part of them is in another one is useful and may lead to different restore strategies. With the folder view, it is akward : you have to create a keyword and to show all subfolders including images  and apply the keyword to all. Believe me, it would be very easy to include a selection of the drive in the find menu, thumbnail view. That's why I cannot blame those who prefer the folder view, the thumbnail view and the find menu are neither satisfying for beginners nor for those accustomed to complex database queries including all operators such as XOR...
    Perhaps inexcusable is a bit of a harsh word.  But I wrote enterprise-level software for 10 years and I know there is a lot going on underneath the hood, and "we should be grateful for what does work" doesn't hold water for me. I still maintain that releasing software when one of the core features became significantly less functional, to the point where it makes that feature unusable, is a very poor choice as far as the existing user base is concerned. (But yes, I also know the pressures that are put on the engineers that are creating the product, and that they are often not the ones that make the decisions about release dates and other things).
    My knowledge of SQL is limited to about 4 sentences, but I do know software. If you have a user task that can happen in less than a second in one view of 30,000 photos and is taking 35 seconds in another view with 30 photos (because no matter what is underneath, what is important is what the user sees, and they took away my ability to see all of them, so "we have to do all this work on the whole tree is a weak excuse at best), that is a major defect, not a design trade-off.
    You wrote, " If the data is outside the database and can change..."  but I still don't see how PSE is reacting to changing data underneath. I changed the data, and it doesn't react at all.  Are you saying that every time I restrict the file view, it checks the entire tree for changes and then doesn't actually act upon them? Also, this doesn't make sense to me, because if I hide many of my files the performance improves significantly -- that tells me it's not about the file structure of things not in my database, but about those in my database.  And if it is the icons that can change, well, the icons are worthless if the view isn't functional.
    Just to be clear for whoever reads this later, I'm not concerned about a one-time cost per session of switching to folder view, though, it would be a lot cleaner if it gave me a progress bar instead of making my OS pop-up "Photoshop Organizer is not responding" boxes. I withdraw my comment about "view full screen" because I can see that there is a workaround, and that was in part user error (though partially also a design choice, since most of the effort of processing my files could be postponed until I was sitting and staring at the first 30, which is how most photo preview software handles it).
    What I am most concerned about is the unusability of folder view for any sort of search or other operations (even stacking three photos in folder view takes *forever*).  How can that not be a defect? Not only that, folder view is buggy -- several times it shows me the wrong photos for a folder (says the folder is A but the pictures are from folder X) and right now, it's telling me I have no zero star photos in any of my directories, when I know I do. Then when I clicked Show All, it's not showing any of my pictures at all.   ("Show all" doesn't seem to work at all in folder view at all).
    If it were a one-time-per-session delay (to account for scanning the file system for changes), but then I could reasonably go back and forth between 2-stars and no-stars and all, stack my photos, rename them, move them from one folder to another, re-arrange all my folders, then that would even be good enough. Take the hit of switching to folder view, and then stay in it for a while. Learn not to go back and forth.   But it doesn't make sense to have a view from which the user cannot perform any tasks on their photos.
    I think I will reclaim the word, "inexcusable" here, sorry     I'll find ways to work around it, though.
    Regarding the feature of selecting all files on a drive...I thought you had said there was a way from folder view to select all the files on a particular drive (i.e, something that it can do that thumbnail view cannot). Did I misunderstand? If that is true, how does one do it?
    I'll end with my previous statement, that I'm available for free beta testing if any of the product engineers would like to work on this issue . I really am a huge fan of the software, which is why I'm so passionate about this topic.
    Lisa

  • My infix to postfix algorithm

    I need som help to finish my algorithm.
    This is what I have so far:
    import java.util.Stack;
    import javax.swing.*;
    public class InfixToPostfix {
    public static void main(String[] args) {
    Object slutt = "#";
    char[] operator = {'^','*','/','+','-'};
    char vParentes = '(';
    char hParentes = ')';
    char[] uOperator = {'^','*','/','+','-','('};
    char[] opPri = {'^','*','/','+','-','(',')','#'};
    int [] infixPri = { 3 , 2 , 2 , 1 , 1 , 4 , 0 , 0 };
    int [] opStackPri = { 3 , 2 , 2 , 1 , 1 , 0 ,-1 , 0 };
    String infixStr = JOptionPane.showInputDialog("infix : ");
    infixStr += slutt;
    String postfixStr = "";
    System.out.println("Infix: "+infixStr);
    Stack stack = new Stack();
    System.out.println ("Stack is empty: "+stack.empty ());
    char c;
    for (int i=0; i<infixStr.length(); i++) {
    c = infixStr.charAt(i);
    if (c == '+' || c == '-' || c == '*' || c == '/') {
    if (stack.empty()) {
    stack.push(String.valueOf(c));
    else {
    // HELP WANTED!!!!!
    else if (c == '#') {
    System.out.println("Postfix: "+ postfixStr);
    System.exit(0);
    else {
    postfixStr += c;
    In the "help wanted" else-loop I want to do the following:
    The operator from stack should pop, and
    it must be compared with the next operator
    from the infix-expression, in according to the
    priority which is given in the opPri, infixPri and opStackPri.
    The if the infix-operator has a higher priority then I push it
    to the stack, else the stack-operator pops and are added
    to the postfix-string, and the next stack operator is popped and
    compared with the same infix-operator. Then again if the infix has
    a higher value I push it to the stack, else the stack-operator is popped
    and added. So on and so on...
    And it's only supposed to handle one digits numbers.
    As you see, I know how it should function, but I am not sure at all
    about the syntax. Can anyone please help me with this?
    thanks!
    torvald helmer>

    Code tags, please: http://forum.java.sun.com/help.jspa?sec=formatting

  • Infix to postfix algorithm

    I need som help to finish my algoritm.
    This is what I have so far:
    import java.util.Stack;
    import javax.swing.*;
    public class InfixToPostfix {
         public static void main(String[] args) {
              Object slutt      = "#";
              char[] operator      = {'^','*','/','+','-'};
              char vParentes      = '(';
              char hParentes      = ')';
              char[] uOperator      = {'^','*','/','+','-','('};
              char[] opPri      = {'^','*','/','+','-','(',')','#'};
              int [] infixPri      = { 3 , 2 , 2 , 1 , 1 , 4 , 0 , 0 };
              int [] opStackPri      = { 3 , 2 , 2 , 1 , 1 , 0 ,-1 , 0 };
              String infixStr      = JOptionPane.showInputDialog("infix : ");
              infixStr           += slutt;
              String postfixStr     = "";
              System.out.println("Infix: "+infixStr);
              Stack stack = new Stack();
              System.out.println ("Stack is empty: "+stack.empty ());
              char c;
              for (int i=0; i<infixStr.length(); i++) {
                   c = infixStr.charAt(i);
                   if (c == '+' || c == '-' || c == '*' || c == '/') {
                        if (stack.empty()) {
                             stack.push(String.valueOf(c));
                        else {
                             // HELP WANTED!!!!!
                   else if (c == '#') {
                        System.out.println("Postfix: "+ postfixStr);
                        System.exit(0);
                   else {
                        postfixStr += c;
    In the "help wanted" else-loop I want to do the following:
    The operator from stack should pop, and
    it must be compared with the next operator
    from the infix-expression, in according to the
    priority which is given in the opPri, infixPri and opStackPri.
    The if the infix-operator has a higher priority then I push it
    to the stack, else the stack-operator pops and are added
    to the postfix-string, and the next stack operator is popped and
    compared with the same infix-operator. Then again if the infix has
    a higher value I push it to the stack, else the stack-operator is popped
    and added. So on and so on...
    As you see, I know how it should function, but I am not sure at all
    about the syntax. Can anyone please help me with this?
    thanks!
    torvald helmer

    Hi there, firstly im not sure why u have done infixPri and opStackPri, i dont think those are necessary?? I have implemented an infix to postfix algorithm that uses only these operators : + - / *. From the help wanted part what you'd want to do is to do this: while the stack is not empty and a '(' character is not encountered, operators of greater or equal precedence from the stack will be popped then appended to the postfixExp else stop the while. Once the while is finished then u push infix onto the stack. Hope this helps. Cheers

  • Oracle's Support for Virtual Iron customers

    Please refer to the blog entry at:
    http://blogs.oracle.com/virtualization/2009/07/oracle_vm_blog_whats_safe.html
    Lot's of chatter out there today about VMware's migration program. Below are a few points for customers to consider…
    1. Oracle is dedicated to the on-going support of Virtual Iron customers and has enhanced the support offering beyond what was previously available from Virtual Iron. Oracle is pleased to be able to offer its Lifetime Support program for Virtual Iron products, which will extend sustaining support for these products and the Virtual Iron Enterprise Edition products indefinitely. Please refer to the Lifetime Support Policy: Oracle Technology Products on the specific support options for Virtual Iron products. In addition, Oracle has retained Virtual Iron support personnel, so that people who provided support prior to the acquisition will continue to do so going forward.
    2. Our intent is to seamlessly combine Virtual Iron's technology with Oracle VM to deliver a product that is unique in the industry both in breadth of functionality, and also depth of features specifically designed to make the full application stack easier to deploy, manage, and support in a virtual environment. Through the combination of Virtual Iron's technology with Oracle VM, customers will be able to benefit from an optimized, efficient application infrastructure with low operating costs. In the meantime, existing customers can be assured that they are fully supported, 24x7 through a world-class support organization.
    3. Oracle VM is a free download. Virtual Iron customers can download and start using Oracle VM today. Oracle VM supports both Oracle and non-Oracle software, and delivers more efficient performance than other virtualization products. Moreover, there's no license cost for Oracle VM. You can benefit from complete virtualization and operating system stack with Oracle Enterprise Linux and Oracle VM that permits dramatically faster and easier deployment of enterprise software.
    4. Compare. Oracle VM support pricing.
    For more information, you can visit:
    * Learn more about Oracle and Virtual Iron
    * Oracle VM

    Got my call and was unable to get all my questions answered (my fault had to cut call short), also I was unable to get the tech called back today so i am hoping that I can tomorrow.
    Preliminary thoughts/answers seam to point that they will sell you additional licenses if you buy support for all of your existing boxes, plus the ones you want to add. Because I use single processor boxes I am trying to get them to license based on the cpu count instead of by the box. If by the box it doubles my cost.
    We talked a great deal about the Oracle VM 2.2 that was released for download and how if compaired to Virtual iron. Oracle is not up to the Virtual Iron level yet but it made some big jumps and will be there pretty soon, by their account. I look forward to seeing the progress and the advances that they will surely incorperate with the huge influx of cash that Oracle will bring.
    Stay tuned.

  • I need help to follow this algorithm to my code

    The algorithm is:
    if operator: while the stack is not empty, pop all operators as long as they are of equal or higher precedence and the top is not '('. Concatenate each operator from stack to postfix. Then push the current operator
    if (c == '+' || c == '-' || c == '/' || c == '%' || c == '*'){
                        while (stack.empty() == false){
                             if (c == '*' && stack.peek() != '(')
                                  postfix += stack.pop();
                             if (c == '/' && stack.peek() != '(' && stack.peek() != '*')
                                  postfix += stack.pop();
                             if (c == '%' && stack.peek() != '(' && stack.peek() != '*' && stack.peek() != '/')
                                  postfix += stack.pop();
                             if (c == '+' && stack.peek() != '(' && stack.peek() != '*' && stack.peek() != '/' && stack.peek() != '%' )
                                  postfix += stack.pop();
                             if (c == '-' && stack.peek() != '(' && stack.peek() != '*' && stack.peek() != '/' && stack.peek() != '%' )
                                  postfix += stack.pop();
                   stack.push(c);

    this is my revision, but still I don't know how it doesn't work when I test my program..can someone tell me where I failed??
    if (c == '+' || c == '-' || c == '/' || c == '%' || c == '*'){
                        while (stack.empty() == false && stack.peek() != '('){
                             if (stack.peek() == '*' || c == '*')
                                  postfix += stack.pop();
                             else if (stack.peek() == '/' && (c == '+' || c == '-' || c =='%' || c == '/'))
                                  postfix += stack.pop();
                             else if (stack.peek() == '%' && (c == '+' || c == '-' || c =='%'))
                                  postfix += stack.pop();
                             else if (stack.peek() == '+' && (c == '+' || c == '-'))
                                       postfix += stack.pop();
                             else if (stack.peek() == '-' && c == '-')
                                  postfix += stack.pop();
                   stack.push(c);
                   }

  • Convertion algorithm - notations

    I need som help to finish my algorithm.
    I wanna convert a string from infix to postfix.
    This is what I have so far:
    import java.util.Stack;
    import javax.swing.*;
    public class InfixToPostfix  {
         public static void main(String[] args)  {
         Object slutt = "#";
         char[] operator = {'^','*','/','+','-'};
         char vParentes = '(';
         char hParentes = ')';
         char[] uOperator = {'^','*','/','+','-','('};
         char[] opPri = {'^','*','/','+','-','(',')','#'};
         int [] infixPri = { 3 , 2 , 2 , 1 , 1 , 4 , 0 , 0 };
         int [] opStackPri = { 3 , 2 , 2 , 1 , 1 , 0 ,-1 , 0 };
         String infixStr = JOptionPane.showInputDialog("infix : ");
         infixStr += slutt;
         String postfixStr = "";
         System.out.println("Infix: "+infixStr);
         Stack stack = new Stack();
         System.out.println ("Stack is empty: "+stack.empty ());
         char c;
         for (int i=0; i<infixStr.length(); i++)  {
              c = infixStr.charAt(i);
              if (c == '+' || c == '-' || c == '*' || c == '/')  { 
                   if (stack.empty())  {
                   stack.push(String.valueOf(c));
                   else  {
                        // HELP WANTED!!!!!
              else if (c == '#')  {
                    System.out.println("Postfix: "+ postfixStr);
                    System.exit(0);
              else  {
                    postfixStr += c;
    }In the "help wanted" else-loop I want to do the following:
    The operator from stack should pop, and
    it must be compared with the next operator
    from the infix-expression, in according to the
    priority which is given in the opPri, infixPri and opStackPri.
    The if the infix-operator has a higher priority then I push it
    to the stack, else the stack-operator pops and are added
    to the postfix-string, and the next stack operator is popped and
    compared with the same infix-operator. Then again if the infix has
    a higher value I push it to the stack, else the stack-operator is popped
    and added. So on and so on...
    And it's only supposed to handle one digits numbers.
    As you see, I know how it should function, but I am not sure at all
    about the syntax. Can anyone please help me with this?
    thanks!
    torvald helmer>

    Hi mikky
    I guess cepstrum vi will be in the next version of "advanced signal processing toolset". Now, it is a beta version. Pwehaps you can ask your local NI representative to get a copy for you.
    Cheers
    Alipio
    "Qod natura non dat, Salmantica non praestat"

  • Design process, help required

    Hi all,
    I am a sort of new be to the java programming world, and still finding my feet to a degree.
    I have a project which consists of me coding a java text editor, with some additional features, such as an online help feature, syntax colouring, bracket matching and a compiler aid i.e. translation of compiler error messages.
    While i feel slightly confident about the coding side of this project, i am not very cler as to how my overall design should look .
    This is realy a software design problen i have rather than a coding problem.
    If anyone can help put me in the right direction it shall be very much appreciated .
    If anybody wishes to ask questions please fell free.
    Thank you

    java_virgin:
    Bear with me while I respond to the others.
    Ceci...:
    Excellent advice, but let me address one pet peeve - MVC is a horrible misnomer. In some instances (enterprise software) the data is a "model" of the underlying reality but in other cases, such as a code editor, the data is not a model, it IS the underlying reality. So will you allow us to call this the Data, View, Controller pattern? Thanks in advance.
    Dr. Clap:
    draw picturesBravo. In 1970 a very experienced programmer told me this: "The first step in writing a program is to turn your computer off." Some truths are immutable.
    java_virgin:
    Thanks for your patience. Here's why.
    I'm writing a code editor. Version 1 was ad hoc based on another I'd written for a book about C++ programming. Version 2 was V1 but rebuilt using DVC (MVC, but it's not a Model, is the Data). Much improved - controller spits commands at the data. Data runs on a separate thread at its own pace. Intermediate command "stack" receives commands and supports multiple undo/redo operations. (Stack converts multiple commands to single ones: Ins "T"'; Ins "h"; Ins "e" becomes Ins "The", etc.)
    Then I realized that I'd want an application framework to surround the editor, so I wrote one. Multiple menu and icon bars, docking at any side or torn off and flying free. Then I hit the wall - didn't know how to interface the framework to the enclosed editor. I've been working on that design since about 2/1 and just today finished it. No nice pattern presented itself. But I'm pretty sure the design will nicely support lots of tools running together, as in NetBeans or Eclipse.
    I'd be glad to answer your original question, but would much prefer that we work together on separate parts of a single project. Is yours a school project? Mine's a personal project aiming for a commercial result.

  • Error while executing web part: System.StackOverflowException: Operation caused a stack overflow

    Hello All,
    I have a list with about 70 or so columns. When I try to access a NewForm for this list, I get an 'Unable to display this web part' error.
    Looking at the Correlation always says it is a:
    "Error while executing web part: System.StackOverflowException: Operation caused a stack overflow."
    I have read many pages on the internet that it is due to an XsltTransformTimeOut value set to 1. I have applied the Feb 2012 CU and tried changing the value to 5, 10, 150, 250 and each time I reset IIS before I tried loading the form again. Each one has
    failed and the correlation says the same thing (stack overflow).
    I do not know what to do next because every page on the net says it is from that timeout value but I have followed the steps properly to change it but nothing has worked.
    Thank you for your help!

    You may be exceeding the number of columns threshold with 70 or so columns in your list.
    Take a look at the Column limits here:
    http://technet.microsoft.com/en-us/library/cc262787.aspx#Column
    Okay, so please help me to understand this. It says the maximum value for single line of text is 276 and the size per column is 28 bytes. How would I know if I have pushed the limit? I just multiplied 28 x the number of single line of text columns in that
    list and the answer is 840. I do have many other columns, such as multiple lines of text and choice. I do not know if the theory above is correct though, because 28 does not go evenly into 276 (276/28 = 9.857)
    Please help me understand how to calculate my fields to see if I have went beyond the limits.
    Thank you!

  • How to calculate the number of operations in Undo/Redo stack?

    How to calculate the number of operations in Undo/Redo stack?
    I tried to override UndoManager.pushUndo method and increment "operationsCounter" there, but pushUndo is called each time I make a change in text.
    Another idea was to override EditManager.finalizeDo and use "operationsCounter" there, but finalizeDo is private...
    Do you have any idea?

    Hi Richard,
    Thanks for the reply. I suggested that existed the more simple way to implement this

  • Need to perform both Queue and stack operations in Visual C# code

    Need to perform both Queue and stack operations, is any Data Structure available for this. or how can i custom create the structure for this?

    Hi,
    In this structure contains base logics of Queue and Stack. Well stack plays major role here with operations of PUSH, POP with additional operation of Queue i.e., ENQUEUE and DEQUEUE.  Here the stack has enqueue and dequeue 
    https://code.msdn.microsoft.com/The-Stacked-Queues-An-11f3703a
    Regards,
    Selva Ganapathy K

Maybe you are looking for