How can I use two single-dimensional arrays-one for the titles and array

I want to Use two single-dimensional arrays-one for the titles and one for the ID
Could everyone help me how can i write the code for it?
Flower
public class Video
public static void main(String[] args) throws Exception
int[][] ID =
{ {145,147,148},
{146,149, 150} };
String[][] Titles=
{ {"Barney","True Grit","The night before Christmas"},
{"Lalla", "Jacke Chan", "Metal"} };
int x, y;
int r, c;
System.out.println("List before Sort");
for(c =0; c< 3; ++c)
for(r=0; r< 3; ++ r)
System.out.println("ID:" + ID[c][r]+ "\tTitle: " + Titles[c][r]);
System.out.println("\nAfter Sort:");
for(c =0; c< 3; ++c)
for(r=0; r< 3; ++ r)
System.out.println("ID:" + ID[c][r]+ "\tTitle: " + Titles[c][r]);

This is one of the most bizarre questions I have seen here:
public class Video
public static void main(String[] args) throws Exception
int[] ID = {145,147,148, 146,149, 150};
String[] Titles= {"Barney","True Grit","The night before Christmas", "Lalla", "Jacke Chan", "Metal"};
System.out.println("List before Sort");
for(int i = 0; i < Titles.length; i++)
   System.out.println("ID:" + ID[i]+ "\tTitle: " + Titles);
System.out.println("\nAfter Sort:");
for(int i = 0; c < Titles.length; i++)
System.out.println("ID:" + ID[i]+ "\tTitle: " + Titles[i]);
Generally you don't use prefix (++c) operators in you for loop. Use postfix (c++).
Prefix means that it will increment the variable before the loop body is executed. Postfix will cause it to increment after.

Similar Messages

  • How can I use two differant iphones on one itunes

    I can i use two differant iphones on one itunes, and keep the content seperate?

    You can sync as many iphones/ipod/ipads as you like to one computer.
    Each is different and is recognized as such

  • Ok, I have two itunes library account one for the PC and one for my Mac, I have my first iphone on my PC, but i just upgrade and I would like to use my new iphone on my Mac but all of my apps and other stuff is in the first library.. How do I put my apps

    ok, I have two itunes librarys account, one for my PC and one for my Mac, I use the PC for my iphone, but I upgrade my iphone and all my apps and
    stuff is on the first itunes library. How do I put the apps from one iphone to the otherusing two dirffernt itunes library? please help..

    Drrhythm2 wrote:
    What's the best solution for this? I
    Copy the entire /Music/iTunes/ folder from her old compouter to /Music/ in her account on this new computer.

  • How can I use two screens to display one window

    Before Mavericks, MAC OS allowed you to use two screens (next to each other) in order to display one (big) window of one application.
    That would mean that a window would start on your left screen en would continue on the right screen.
    With Mavericks, however, this not possible any more. The window of the application can only be seen on ONE of the screens (i.e. the left one).
    Can any one tell me whether I've missed certain options or how to adjust my settings in order to get this feature back?

    Hey CGNL,
    First, if you haven't already, set up the displays as an extended desktop:
    Choose Apple menu > System Preferences, click Displays, then click Arrangement.
    Follow the onscreen instructions.
    Then, use Mission Control preferences to uncheck/turn off the option for "Displays have separate Spaces":
    Choose Apple menu > System Preferences, click Mission Control
    Uncheck "Displays have separate Spaces"
    That should enable you to stretch whatever window you want across multiple displays.
    via: OS X Mavericks: Connect multiple displays to your Mac
    http://support.apple.com/kb/PH13814
    and
    OS X Mavericks: Mission Control preferences
    http://support.apple.com/kb/PH13925
    Welcome to Apple Support Communities!
    Have a good one,
    Delgadoh

  • How can I use a generic indifferently in one of the generic's member functions?

    I'm curious about the following situation:
    I'd like to access another generic's private member in a constructor. How can I do that irrespective of the generic's actual type?
    Here's a sample of what I'm trying to accomplish:
    public class C<T>
    private int _hdc;
    // private T _someMember;
    public C()
    this._hdc = CreateHdc();
    public C(C src) // what would be the correct signature here to be able to run the assignment in ::f() below?
    this._hdc = src.hdc;
    function f()
    C<int> a = new C();
    C<string> b = new C(a); // how can I get this to work?
    Do I need to create a non-generic base class to be able to use a differently typed object in the construtor? Or is there some C# construct that will allow me to define an untyped generic parameter and only use the untyped members from that parameter?
    Still people out there alive using the keyboard?
    Working with SQL Server/Office/Windows and their poor keyboard support they seem extinct...

    >>I'd like to access another generic's private member in a constructor.
    You cannot access a class' private member from any other class directly. You could expose a private field through a property or define a public method (or constructor) that sets the private field though.
    >>How can I do that irrespective of the generic's actual type?
    You cannot assign a string field to an int value or the other way around without converting the value to a string/int first.
    A C<int> object always has an int field - the generic class is not really a type of its own but rather a "blue-print" or a template for a type - and you cannot assign this one to a string value.
    Since the C<string> class Always has a string field you need to convert the int value of the C<int> object to a string before you can ever assign the string field to this value:
    C<int> a = new C();
    C<string> b = new C(a.ToString());
    C<int> and C<string> are two completely different types. They are not related to each other and as mentioned you cannot assing a string field to an int value.
    >>Or is there some C# construct that will allow me to define an untyped generic parameter and only use the untyped members from that parameter?
    There is no such thing as "an unyped generic parameter" in C#. T always refers to a type and you must specify the type when you create an instance of the generic type.
    Please remember to close your threads by marking helpful posts as answer and then start a new thread if you have a new question.

  • How can I run two instances of Firefox: one in Safe Mode and another in Normal Mode?

    I think my question says it all.

    You can't simultaneously run a normal instance and a Safe Mode instance using the same profile. So step one is to create a new profile.
    * [[Use the Profile Manager to create and remove Firefox profiles]]
    Right-click the desktop and choose New, then Shortcut. As the location of the item, use the following, substituting the placeholder profile name with the actual profile name you chose earlier.
    "C:\Program Files (x86)\Mozilla Firefox\firefox.exe" -no-remote -p NameOfTheProfile
    * https://developer.mozilla.org/docs/Mozilla/Command_Line_Options

  • How Can i Use two Different Public IP Addresses no my DMZ with ASA Firewall.

    How To Using Two Different Public IP Address on My DMZ with ASA 5520
    Postado por jorge decimo decimo em 28/Jan/2013 5:51:28
    Hi everyone out there.
    can any one please help me regarding this situation that im looking for a solution
    My old range of public ip address are finished, i mean (the 41.x.x.0 range)
    So now i still need to have in my DMZ another two servers that will bring some new services.
    Remember that those two server, will need to be accessable both from inside and from outside users (Internet users) as well.
    So as i said, my old range of public ip address is finished and we asked the ISP to gives some additional public
    ip address to address the need of the two new servers on DMZ. and the ISP gave us the range of 197.216.1.24/29
    So my quation is, on reall time world (on the equipment) how can i Use two different public ip address on the same DMZ
    on Cisco ASA 5520 v8??
    How my configuration should look like?
    I was told about implementing static nat with Sub Interfaces on both Router and ASA interface
    Can someone please do give me a help with a practical config sample please. i can as well be reached at [email protected]
    attached is my network diagram for a better understanding
    I thank every body in advance
    Jorge

    Hi,
    So looking at your picture you have the original public IP address range configured on the OUTSIDE and its used for NAT for different servers behind the ASA firewall.
    Now you have gotten a new public IP address range from the ISP and want to get it into use.
    How do you want to use this IP address range? You want to configure the public IP addresses directly on the servers or NAT them at the ASA and have private IP addresses on the actual servers (like it seems to be for the current server)?
    To get the routing working naturally the only thing needed between your Router and Firewall would be to have a static route for the new public network range pointing towards your ASA OUTSIDE IP address. The routing between your Router and the ISP core could either be handled with Static Routing or Dynamic Routing.
    So you dont really need to change the interface configuration between the Router and ASA at all. You just need a Static route pointing the new public IP address towards the ASA outside IP address.
    Now when the routing is handled between the ISP - ISP/Your Router - Your Firewall, you can then consider how to use those IP addresses.
    Do you want to use the public IP addresses DIRECTLY on the HOSTS behind the firewall?This would require you to either configure a new physical interface with the new public IP address range OR create a new subinterface with the new public IP addresses range AND then configure the LAN devices correspondingly to the chosen method on the firewall
    Do you want to use the public IP addresses DIRECLTY on the ASA OUTSIDE as NAT IP addresses?This would require for you to only start configuring Static NAT for the new servers between the inside/dmz and outside interface of the ASA. The format would be no different from the previous NAT configuration other than for the different IP addresses ofcourse
    Of the above ways
    The first way is good because the actual hosts will have the public IP addresses. Therefore you wont run into problems with DNS when the LAN users are trying to access the server.
    The second way is the one requiring the least amount of configurations/changes on the ASA. In this case though you might run into problem with DNS (to which I refer above) as the server actually has a private IP address but the public DNS might reply to the LAN hosts with a public IP address and therefore connections from LAN could fail. This is because LAN users cant connect to the servers OUTSIDE NAT IP address (unless you NAT the server to public IP address towards LAN also)
    Hopefully the above was helpfull. Naturally ask more specific questions and I'll answer them. Hopefully I didnt miss something. But please ask more
    I'm currently at Cisco Live! 2013 London so in the "worst case" I might be able to answer on the weekend at earliest.
    - Jouni

  • How can I use two accounts ?

    How can I use two accounts (mine and my wife's) to PhotoStream to my mac? I have to turn off photo stream for one or the other...can't I just leave two accounts logged on so that the photos from my iphone and hers both go to my mac?

    Photostreaming across machines requires to use the same Apple-ID on all of these machines or devices. Share all of iclouds account stuff or nothing at all . No way around as icloud is designed that way. Photostream is not designed as a sort of gallery to share with outsiders. It is for your personal entertainment .

  • How can I use two monitors to increase workspace?

    how can I use two monitors to increase workspace?

    Drag the tabs of any After Effects windows you want to the second monitor.

  • How can we use two BOM

    Dear all,
    my scenario is in this way way-
    how can we use two BOM for same material.first BOM for inhouse production. Second one for Subcontracting.(means i have to create Purchase order for partial qty.

    Dear
    1.Goto MM02-MRP4 view -Maintain two Production Version based on two BOM ( Alternative1 with Routing will be PV1 will be used for production in house  where as Alt2 with routing having PP03 as control key for external operation -PV2 )
    2.Assign the relavant production Version-PV2 in Subcontracting Info Record in ME11
    Now, based on the production version assigned in Info Record system suggests the BOM while BOM explosion in Subcon Purchase Order
    REFER : Subcontracting & BOM  alternative
    Hope this will solve your issue
    Regards
    JH
    Edited by: Jiaul Haque on Sep 29, 2010 1:27 PM

  • How can I combine two itunes accounts into one?

    How can I combine two itunes accounts into one?

    Items purchased from the iTunes Store are permanently associated with the account from which they were originally purchased.  Apple provides no way to change this.
    However, if you wish to put content from two accounts into a single iTunes library, you can easily do so.  Use the command File > Add File (or Folder) to Library.

  • How can I have two itunes accounts on one computer?

    How can I have two itunes accounts on one computer?

    Not sure what you mean.
    An account is a user name and password.
    Sign into whichever account you want to use for purchasing.
    Authorize the computer for both account to listen to the content.

  • How can I combine two video files into one finished file?

    I'm making a video of a guitar player.  I'm using two cameras simultaneously.  One gives the overall wide shot, and the other is zoomed in on his hands.  Both cameras run at the same time.  I would like to use the wide shot as the main video, and occasionally fade in clips from the zoomed in shot to show details of his playing.  I can manually line up both files so they are synchronized.  How do I cut a clip out of the main (wide) shot, leave the gap there, and insert a clip from the closeup?  I'm putting the two video files on two of the video timelines and synchronizing them that way.
    Any suggestions on how to proceed?

    The effect you are looking for is 'Picture in Picture'. If you want the gap to be there for the duration of the timeline add some 'black video' - from the Tasks Pane> New Item - on the video track above the main track. Resize / position it to where you wish it to be.
    Then with your second clip (now on video track 3)
    Do the same sizing / positioning for it.
    split video and audio and delete or disable the audio.
    Cut it where you want the various start/ends of the fade to be.
    Delete, or just disable (right-click) the unnecessary segments.
    Apply fade in / out to the remaining segments.
    [EDIT]
    Also check out the 'Presets' in Video Effects. There are a variety of PiP presets that may do what you need.
    [/EDIT]
    Cheers,
    Neale
    Insanity is hereditary, you get it from your children

  • How can someone use a stolen iphone? does erasing the phone (which I feel like I should do) make it easier for the thief to use the iphone?  If I don't erase it, it doesn't seem like anyone should be able to use the phone because of my password.

    how can someone use a stolen iphone? does erasing the phone (which I feel like I should do) make it easier for the thief to use the iphone?  If I don't erase it, it doesn't seem like anyone should be able to use the phone because of my password. Also, is it possible to retrieve anything that has been sent to the phone (i.e. text messages) since it was stolen through icloud? The "find my iphone" app says the device is offline but it rings when I call my number -- any idea how that would be the case? Thanks!!

    You have a password, so good move on your part.  Whether you erase it or the thief does, they still get to use the iPhone as theirs.  Which is more important (pick one), protecting your data or punishing the thief?
    Ringing occurs at the carrier.  Chances are you're going to voicemail after only two or three rings.  If you have an iCloud backup also a good move.  Re-read my question in the first paragraph.

  • HT2736 How can I gift a single song (i.e. not the whole album) to a friend?

    How can I gift a single song (i.e. not the whole album) to a friend?

    If you're trying to do this from an iOS device, you can't. You'll need to use iTunes on a computer to be able to give a single song. If you are using a computer, tell us what OS and iTunes it's running and where you're encountering difficulty and we'll try to help further.
    Regards.

Maybe you are looking for

  • I can't seem to get  my iCloud working between my iPhone and iPad

    My wife and I recently purchased (in This order) an iPad, then 2 iPhones, then a second iPad. My iCloud on my devices is working fine. We are having trouble getting my wife's to work. I checked again, and was sure I had done what I was supposed to do

  • I lost one of four black round rubber patch at base of my macbook pro. Where can I buy the new one?

    At the back of all Macbook pro will have 4 round rubber patch. I lost one of them. Where and how can I buy the new one?

  • Reading project... stops at 28%

    Just installed Leopard to a new volume, and hat all Application files transferred to it during the install. Final Cut Pro works with the exception of one (the most important one!) project. When trying to open it, it stalls at 'Reading project... 28%'

  • Steps to copy datafiles in another database

    Hi, I want to use datafiles of another 10g database ,installed on different server, in my local 10g database. Please educate me on steps I need to take to do this. Kindly inform me if any further information is required in this regard. Thanks Harbind

  • Export KM Content

    Good morning, I need export KM Content, I see in other message: http://help.sap.com/saphelp_nw04/helpdata/en/35/4cf72bfe18455e892fc53345f4f919/frameset.htm But, how I can begin?? Thanks, Mercedes