Printing values from a class


 
Thread Tools Search this Thread
Top Forums Programming Printing values from a class
# 1  
Old 05-07-2014
Printing values from a class

I have a class

and want to print values in MOD using

L = new Layer* [NL];

How can I print the values in MOD using this object L???


Code:
class Layer  

{

public :

  Model*  MODP;
  Model*  MODS;


Code:
class Model  

{
    
protected:

  int     NX;
  int     NZ;
  Matrix<float>  MOD;

# 2  
Old 05-20-2014
Depends on Matrix; is this that class? Matrix Class (System.Drawing.Drawing2D)
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Array not printing values if used in a loop

Hello! I'm making an English to Morse Code translator and I was able to mostly get it all working by looking through older posts here; however, I have one small problem. When I run it it's just printing spaces for where the characters should be. It runs the right amount of times, and if I try... (3 Replies)
Discussion started by: arcoleman10
3 Replies

2. Shell Programming and Scripting

Printing null values in awk

Hi, I have a csv file with given details abc.txt 123,ra,point,,there 232,ba,points,home,pheer I want to get those values and store them in different variables: Code: while read line do echo $line |awk -F"," '{print $1" "$2" "$3" "$4" "$5"}'|read dbt_acct val_dt crncy AMT... (11 Replies)
Discussion started by: rahulsk
11 Replies

3. Shell Programming and Scripting

Printing $values using awk

Hi All I had requirement where I need to re-order columns in a file by using a control file. here is the ctrl file c1 c2 c3 source file c3 | c1 | c2 a | b| c I should create output file based on the ctrl file columns o/p should look like this c1 | c2 | c3 b| c|a I wrote some... (9 Replies)
Discussion started by: gvkumar25
9 Replies

4. Shell Programming and Scripting

Shell : eliminating zero values and printing

I have a log file containing the below data and should have the output file as below. and the output file should not contain any 0 values. Eg. It should not contain 0000000:0000000 in it. input.txt Media200.5.5.1 00010003:065D1202 Media100.5.5.2 7,588,666,067,931,543... (6 Replies)
Discussion started by: scriptscript
6 Replies

5. UNIX for Dummies Questions & Answers

Printing all the values in the middle of two columns

Hi, I have a tab delimited text file with three columns: Input: 1 25734 25737 1 32719 32724 1 59339 59342 1 59512 59513 1 621740 621745 For each row of the text file I want to print out all the values between the second and third columns, including them. The... (3 Replies)
Discussion started by: evelibertine
3 Replies

6. Programming

Printing float values in C

Hi, I have small problem to print float value in the fallowing code float Cx, W,f=250000, Cr=92.00,pi=3.14; W=2*pi*f; Cx = 1/W.Cr; //Cx value will be come around like 7.07E-9. printf("capacitance value: %.10f",Cx); I am trying to print Cx value using above code but it was not... (3 Replies)
Discussion started by: veerubiji
3 Replies

7. Programming

Filling the class from values taken from user input

I have a program that accepts user input. For example I have mdacc that the user sets the value. I then have a class which stores the value set by the user. I use set_param to set the values in the class. I pass through it the list of user defines arguments from argv. What would be the opinion on... (0 Replies)
Discussion started by: kristinu
0 Replies

8. Programming

Printing class address!

Hello everyone, I have this code which prints the address of the object of a class....bt. what if I want to print the address of the class? #include <iostream.h> class har{ }; int main() { har a; cout<<(&a); } I would really appreciate if someone can help! Thanks!!!!! (1 Reply)
Discussion started by: mind@work
1 Replies

9. Shell Programming and Scripting

printing two values with TAB in between

Dear friends, I want to print variables' values in certain format where space between two values of variables is "a tab" I tried where I provided "tab" between two varibales. But when it print values on screen its giving me output without spaces in two values. Request you to help me in... (7 Replies)
Discussion started by: anushree.a
7 Replies

10. UNIX for Advanced & Expert Users

Printing defaulted values

I have written a phyton script that accepts command line arguments. I am setting defaults for some of them if the user does not specify them. However I want to print the user values and the defaulted values seperately. However, once I set the default values, then I cannot use if... (0 Replies)
Discussion started by: kristinu
0 Replies
Login or Register to Ask a Question