473,490 Members | 2,495 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Manipulation to be done in arrays.

i want to create a 10x10 matrix(with user input)

for e.g., i have given a small sample of 2x2 matrix and below is the description regarding what manipulation i want to do.

say for e.g my matrix is
0.76 1
0 0.3

now what i want to do is that, whenever the value in the matrix is greater than 0.25, i want to print 1 and if it is less than 0.25 than i want to print 0 and if it is 0 or 1 then let it be as it is....
so the answer for my above matrix should be

1 1
0 0
Oct 6 '10 #1
1 1133
Dheeraj Joshi
1,123 Recognized Expert Top Contributor
Do you have a code for this?
You can check the number inside a loop and determine the condition and change the value with 0 or 1.

Regards
Dheeraj Joshi
Oct 7 '10 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

6
2276
by: Robert Kern | last post by:
I'm in the middle of writing a scientific program with a number of very, very long formulae. You can see a typical one below. What I would like to do is to parse this code to yield an AST, identify...
3
1668
by: Klaus Rudolph | last post by:
Hi all, I have 2 classes, the second one should include an array of the first on. The first class should not have a default constructor. How could I use an array of the first classes? If it is...
34
4128
by: Christopher Benson-Manica | last post by:
If an array is sparse, say something like var foo=; foo=4; foo='baz'; foo='moo'; is there a way to iterate through the entire array? --
2
1141
by: Gary Smith | last post by:
I am using Visual Basic for ASP.Net programming. I would like to kow the string manipulation using multi dimensional arrays. for example. How to declare multi dimensional array How to read and...
6
2726
by: Dennis | last post by:
I was trying to determine the fastest way to build a byte array from components where the size of the individual components varied depending on the user's input. I tried three classes I built: (1)...
21
18656
by: KK | last post by:
How can I find out the maximum or minimum values out of many values in an array. I have an array in Access that loads upto 20 values depending on a sql query. I would like to find out the min and...
38
5077
by: Peteroid | last post by:
I looked at the addresses in an 'array<>' during debug and noticed that the addresses were contiguous. Is this guaranteed, or just something it does if it can? PS = VS C++.NET 2005 Express...
12
2517
by: Sheldon | last post by:
Hi, I have two arrays that are of the same dimension but having 3 different values: 255, 1 or 2. I would like to set all the positions in both arrays having 255 to be equal, i.e., where one...
8
2313
by: martin-g | last post by:
Hi. I have a question on arrays in VBA. I'm a C++/C# programmer and didn't expected arrays in VBA to be so helpless, or maybe it only seems to me that they are helpless. For example in C++ we...
16
2503
by: mike3 | last post by:
(I'm xposting this to both comp.lang.c++ and comp.os.ms- windows.programmer.win32 since there's Windows material in here as well as questions related to standard C++. Not sure how that'd go over...
0
7112
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7146
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
1
6852
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
7356
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
4573
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3084
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
1389
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
628
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
277
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.