Top Answer
User Avatar
Wiki User
Answered 2008-02-18 09:00:35

import java.util.Vector; suppose-:::: test t=new test(); /**this is how we add elements to vector*/ Vector v=new Vector(); v.addElements(t);

User Avatar

Your Answer


Still have questions?

Related Questions

How do you call 2 or more objects in c plus plus?

It's not clear what you mean by "call 2 or more objects". Object's aren't "called", they are instantiated. Once instantiated you may "call" (invoke) the member methods associated with those objects, or invoke functions that operate upon those objects. To invoke the same member method on 2 or more objects, simply place those objects in a vector (by reference), then iterate over the vector: void f (std::vector<my_object*> objects) { for (auto foo : objects) foo->bar(); // invoke the bar method for each foo object in objects }

The measure of an objects speed and direction is the objects?

It is known as the vector.

What does vector's member size() do?

The vector size() member returns the current size of the vector, in elements.

How do you display the elements in a vector to the user?

Generally vectors are displayed in parenthesis with the vector components separated by a comma. If there are vectors within another vector then brackets are used for the internal vector.

Is Photoshop a bitmap or a vector program?

It is bitmap based program but you can work and with vector objects inside Photoshop. To export vector objects from Photoshop you can through Save or Save As > Photoshop PDF. Also vector outlines can be exported for Illustrator from File > Export

Is Asmospheric pressure a scalar or vector?

The answer is simple, define both a scalar: 1 variable, and a vector: 2 variables. Pressure is a force of space over time, therefore Asmospheric pressure is a vector since it applies both space and time using 2 variables.

What is a objects speed and direction?

velocity, or velocity vector.

Can vector store string values in java programming?

A Vector can store any objects, so yes.

How are GIF images stored?

As raster images, so if you have vector objects and choose to save as gif, you will not be able to change vector objects next time you open image.

What is the product of an objects mass and velocity called?

That is called momentum. Since velocity is a vector, momentum is also a vector.

Speed and direction of an objects motion?

the object's velocity vector

What describes an objects direction and speed?

It's velocity (vector)

Can you Explain the concept that all objects have momentum?

If all objects have energy as in E=mc^2 then all objects have momentum P= mc. The universe consists of two types of "objects" scalars and vectors. Scalar momentum =mc, and Vector momentum =mv. If you only consider vector momentum then only objects with velocity have momentum. Here the problem is the Relativity of velocity. If there is no relative velocity then there is no vector momentum. There still is scalar momentum mc for all objects.

What vector represents the distance and direction of an objects change in position?


Are human beings vector quantity or scalar quantity?

They are neither. "Vector quantity" and "scalar quantity" applies to measurements, not to complex objects.

What is the main characteristic of a vector image?

Vector images use geometry -- points, lines, curves, shapes and polygons -- to display images in computer graphics.

What is inventory displayer c plus plus?

// Inventory Displayer // Demonstrates constant references #include <iostream> #include <string> #include <vector> using namespace std; //parameter vec is a constant reference to a vector of strings void display(const vector<string>& vec); int main() { vector<string> inventory; inventory.push_back( "sword"); inventory.push_back( "armor"); inventory.push_back( "shield"); display(inventory); return 0; } //parameter vec is a constant reference to a vector of strings void display(const vector<string>& vec) { cout << "Your items:\n"; for (vector<string>::const_iterator iter = vec.begin(); iter != vec.end(); ++iter) { cout << *iter << endl; } }

Which display device is suited for cad system a a crt with vector referesh monitor b crt with raster scan monitor c plasma panel display d led display?


Is gravity a vector quantity?

Gravity is not a quantity at all. The force of attraction between two objectsthat arises due to gravity is a vector quantity.

Are human being vector quantity or scalar?

The concepts of "vector quantity" or "scalar quantity" apply to simple properties; not to complex objects.

How do you implement vector?

import java.util.Vector; public class VectorTest { /** * @param args */ public static void main(String[] args) { //instantiating a vector Vector vct = new Vector(); //Add objects to a vector vct.add("One"); //getting values from the vector String val = (String) vct.get(0); //vector size System.out.println("Vector size is: " + vct.size()); //removing elements from a vector vct.remove(0); } }

What tools machines?

The machines are said to transform vector objects used by the chip.

What is the purpose of illustrator?

It is vector based software and purpose is for creating and manipulating vector objects which includes Type, Shapes.. and is best product in category, you can use it for creating logos, page layout objects, PDF files and so on..

Difference between vector graphics display and raster scan display?

A "raster scan" display is what you are most probably looking at right now. The image is constructed of many small dots. In modern color displays each dot is made up of a red, a green, and a blue component. Vector displays shoot a beam that sweeps over the screen . One example that you may have seen is an oscilloscope. There the beam of electrons is deflected by electrically charged plates to change it's direction. there are no pixels per say in a vector display.

What is the difference between vector and bitmap graphics?

Difference between a vector and bitmap graphics is that a vector is a format of a drawing whereas bitmap is a format of a photo. * the advantages of a vector is that the drawing can be stretched to any size without ruining the quality and bitmap is faster to display .Bitmap graphics as being stored in a literal fashion, then Vector Graphics, stored representative are their opposites.