Posts
 
Reputation
Joined
Last Seen
0 Reputation Points
Unknown Quality Score

No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.

~2K People Reached
About Me

Student

Interests
Music: drums, bass, guitar, synths, electronic composition. Sports: golf, soccer, swimming, tennis,…
Favorite Forums
Favorite Tags
c x 13
c++ x 11
java x 10
Member Avatar for g_loughnan

Hi All, I'm trying to figure out how to pass an object to a function by constant reference. If I write a single class, can I write a function in this class that accepts an object of this class by constant reference? If so (or in any case) how does …

Member Avatar for StuXYZ
0
609
Member Avatar for g_loughnan

Hi Lads, I'm trying to read from one spreadsheet, extract the contents of certain cells, and write them into a new spreadsheet. I've read from one spreadsheet fine, but when I try to write to a new spreadsheet, the output file is empty and I can't see why. Can anyone …

0
70
Member Avatar for g_loughnan

Hi guys, I haven't a clue why this won't compile! I think the compiler is confusing multiplies as pointers. Here's my code: [code=c] #include <stdlib.h> #include <stdio.h> #include <math.h> #define pi 3.14159265; double data[] = { -0.15709,-0.25413,-0.1545,-0.011505,-0.052141,-0.24125,-0.28251,0.020464,0.48291,0.69804,0.46961,0.019997, -0.26036,-0.22194,-0.059284,-0.027764,-0.14373,-0.21843,-0.14153,-0.030971,-0.060482,-0.19966, -0.217,0.037288,0.41287,0.58642,0.40239,0.036834,-0.19954,-0.1839,-0.06484,-0.042241,-0.13189,-0.18949,-0.12998, -0.044059,-0.064511,-0.16527,-0.1656,0.048371,0.35412,0.8441,0.76091,-0.086579,-0.56076,-0.38969, -0.0037447,0.066327,-0.19043,-0.35463,-0.18658,0.055369,-0.015147,-0.35243,-0.4718, -0.038401,0.66734,0.99976,0.64583,-0.038856,-0.43599,-0.32307,-0.031074,0.023928,-0.17255,-0.29875, -0.16944,0.016309,-0.037833,-0.29157,-0.36583,-0.0038886,0.56681,0.834,0.54992,-0.0043523,-0.33768,-0.2678, -0.048722,-0.0065075,-0.15722,-0.25426,-0.15463,-0.011604,-0.052198,-0.24126, -0.28247,0.020554,0.48303,0.69817,0.46973,0.020092,-0.26031,-0.22194,-0.059329,-0.027849,-0.14384,-0.21855, -0.14164,-0.031061,-0.060533,-0.19967,-0.21696,0.037369,0.41298,0.58653,0.4025,0.036919,-0.19949,-0.1839,-0.06488, -0.042318,-0.13199,-0.1896,-0.13009,-0.044141,-0.064557,-0.16527,-0.16556,0.048444,0.35422,0.84421,0.76101, -0.086502,-0.56072,-0.38968,-0.0037807,0.066258,-0.19052,-0.35473,-0.18667,0.055296,-0.015189,-0.35243,-0.47177, -0.038335,0.66742,0.99986,0.64592,-0.038786,-0.43595,-0.32307,-0.031107,0.023865,-0.17263,-0.29884, -0.16952,0.016243,-0.03787,-0.29157,-0.3658,-0.0038291,0.56689,0.83409,0.55,-0.0042893,-0.33765,-0.26779, …

Member Avatar for g_loughnan
0
100
Member Avatar for g_loughnan

Hi all, I'm trying to figure out how I can call the function estimate from the main. It takes as input: [code=c] float data[], int n, int m; [/code] and should output the float *xms and the float array float d[]: [code=c] float *xms, float d[] [/code] I don't know …

Member Avatar for g_loughnan
0
125
Member Avatar for g_loughnan

[code=c] #include <stdio.h> #include <stdlib.h> #include <math.h> void estimate(float data[], int n, int m, float *xms, float d[]) int main(void) { double data[] = { //Loads(~1000) of data vavues between +1 and -1. Ex: -0.15709, -0.25413,... }; float xms[m]; float float d[m]; for (i=0;i<m;i++) { //Function call here to fill …

Member Avatar for g_loughnan
0
94
Member Avatar for g_loughnan

Hi all, I've been trying to paint an image to a JPanel with no success. Could someone help me figure this out? [code=java] mport javax.swing.*; import java.awt.*; import java.awt.event.*; import java.io.File; import java.util.Vector; import java.awt.image.*; public class PhoneInterface1 extends JFrame implements ActionListener { private JPanel imagePan = new JPanel(); private …

Member Avatar for Ezzaral
0
460
Member Avatar for g_loughnan

Hi there, I have this null pointer exception error in my code which I can't fix. I'm just trying to create an interface which can display an image, text and 12 buttons all at once. I've checked out loads of other threads, but I can't see where the Null entry …

Member Avatar for g_loughnan
0
145
Member Avatar for g_loughnan

Hi all, Just have a curiosity about multiple inheritance. I have defined two classes, each of which returns a string to described an object of that class. I have also made another class which inherits from both of the above classes. I want to define a function in the derived …

Member Avatar for g_loughnan
0
67
Member Avatar for g_loughnan

Hi there, I'm trying to create a demonstration of a modified copy constructor. As can be seen from the code below, I've created a class called Track and defined a copy constructor such that a new object of type "Track" can be defined with the same track artist and album …

Member Avatar for g_loughnan
0
87
Member Avatar for g_loughnan

Hi there, I'm trying to write a program to accept some details about mp3 files, and store them in an array. I am also hoping to process some of the parameters of each entry to the array. I am trying to create an object of type "Track", and then define …

Member Avatar for g_loughnan
0
90
Member Avatar for g_loughnan

Hi Guys&Gals, Just wondering, when using separate compilation, should the class definition and method definition(s) for a derived class be put in separate header and source files from the base class? Thanks, Ger.

Member Avatar for g_loughnan
0
71