Posts
 
Reputation
Joined
Last Seen
0 Reputation Points
100% Quality Score
Upvotes Received
2
Posts with Upvotes
2
Upvoting Members
2
Downvotes Received
0
Posts with Downvotes
0
Downvoting Members
0
0 Endorsements
Ranked #4K
~7K People Reached

19 Posted Topics

Member Avatar for CPT

First, to explain what I want to do: I have a folder structure like this: BSDS300\images\test\ -which contains JPEG files, and some other files(only .jpg files are of interest) BSDS300\human\color\ -which contains many folders, in which I have .seg files with the same name as the .jpg file Example: BSDS300\images\test\3096.jpg …

Member Avatar for RikTelner
0
374
Member Avatar for CPT

currently I have a class function: class MyClass{ static int E(int A,int B, int C){ //function code } }; //and I call it like this : MyClass::E(1,2,3); //what I would like to do is call it in this way: E(1,2,3); //my current macro definition is this #define E(a,b,c) Myclass::E((a),(b),(c)) how …

Member Avatar for JasonHippy
0
312
Member Avatar for CPT

Currently I have something like this: class FileWritter{ ofstream file; public: FileWritter(string filename,A_Class a){//A_Class is class which has defined the >> and the << operators file.open(filename.c_str()); file<<a; } ~FileWritter(){ file.close(); } }; what I want is to have something like this: template <class AbstractClass> class FileWritter{ ofstream file; public: FileWritter(string …

Member Avatar for mike_2000_17
0
515
Member Avatar for CPT

Hello everyone, I'm having problems grasping some concepts of parallel programming; to be more precise, given some pieces of code, I have to determine which of them can be parallel and which cannot(this was in a test in a parallel programming class): a) a=2; b=3; //yes-variables are independently initialised b) …

Member Avatar for rubberman
1
250
Member Avatar for CPT

Hello everyone, I've encounterred a problem that I cannot seem to overcome. For the program to compile there are a few steps necessary to take: from the website [Click Here](http://osl.iu.edu/research/mpi.net/software/) on the download page, one would need to download and install: 1. MPI.NET SDK 2. Microsoft Compute Cluster Pack SDK(this …

Member Avatar for Ketsuekiame
0
383
Member Avatar for CPT

i've just started learning the C# language and this is my first program to use threads. I don't understand why the consumer thread doesn't get called( only after the producer has stopped)and when it gets called it doesn't consume anything, also I've noticed that the majority of produced elements are …

0
188
Member Avatar for GeekTool

someone correct me if I'm wrong: both bitwise and logical operators are the representation of the boolean function with the same names(better read on that first as I suspect the fact that you haven't) the diference is that the bitwise ones operate on bits(it doesn't matter if your data type …

Member Avatar for NormR1
0
561
Member Avatar for CPT

Heloo,this wil be my first post here, the reason for that is I can't figure this one out by myself public class Client extends Thread{ Socket socket = null; ServerResponse sr = null; private class serverResponse extends Thread{ InputStream in = null; public serverResponse(Socket socket) throws IOException{ if (socket == …

Member Avatar for NormR1
0
480
Member Avatar for CPT

[code="C++"] class item { string name; string identifier; public: item( string name,string id):{this->name=name;this->identifier=id;} friend ostream& operator<<(ostream&, const item&); friend istream& operator>>(istream&, item&); }; ostream& operator<<(ostream& out, const item& temp) { out<<item.name<<" "<<item.identifier<<endl; return out; } istream& operator>>(istream& in, Cmessage& temp) { getline(in,item.name);//in case sring has space char getline(in,item.identifier); return in; …

Member Avatar for mike_2000_17
0
176
Member Avatar for CPT

I know that you can use assembly combined with C++(either inline or using modules written completely in assembly, linked with the rest of the program), and I was curious how does a program written in different programming languages(eg Mozilla Firefox)work, and how it gets built.

Member Avatar for Celtrix
0
110
Member Avatar for portege

[QUOTE=Ancient Dragon;235863] [code] s = "0123456789abcdefghijklmnopqrstuvwxyz"[value % base] + s; [/code][/QUOTE] offtopic:I'm having trouble understanding this line, so you're initializing s with "01..yz" but what does the [code][value % base] + s[/code] part actually do?

Member Avatar for raptr_dflo
0
3K
Member Avatar for CPT

So it's this program which isn't behaving as it should. these are the classes I'm haing problems with: [code]#ifndef _CMENU_H_ #define _CMENU_H_ #include "Vec2.h" #include "Background.h" #include "Sprite.h" #include "BackBuffer.h" class Button { public: enum ButtonState { NORMAL, //when cursor is not near the button ANIMATED //mouseover event }; Button(const …

Member Avatar for m4ster_r0shi
0
159
Member Avatar for CPT

just as the title says i have a problem with serializzing class which has a pointer to class. so this is a mock-up of my class structure [code] class X{ private: int number; public: int set_number(int); int get_number(void); //I'm defining the stream operators so class will act as primitive data …

Member Avatar for L7Sqr
0
96
Member Avatar for CPT

so these are my structures: [CODE] struct information { int Id; char name[20]; }[/CODE] that structure I use in my tree structure [CODE] struct node{ information *employee; node *left,*right }[/CODE] and I have a generating function: [CODE] node* generate_tree_from_file(void) { node* tree=malloc(sizeof(node)); employee* emp=malloc(sizeof(employee)); int NoEmployees; FILE *input_file; input_file=fopen("emp.bin","r"); if(input_file) …

Member Avatar for nezachem
0
147
Member Avatar for CPT

As the title suggests I need to write the class of a graph object. It is required that I write a function that prints the graph determine if the graph has conex components,what are the cinex components, if the graph has cycles, and to determine the shortest and longest road …

Member Avatar for Tellalca
0
132
Member Avatar for CPT

So I've implemented the binary search tree but i get an error from the insertion function this is my code: [CODE]#include<iostream> #include<stdlib.h> #include<malloc.h> using namespace std; struct NOD{ int inf; struct NOD *left; struct NOD *right; }; NOD *root; bool Erase(int nr); void Insertion(int nr); int Search(NOD* node,int target); void …

Member Avatar for Taywin
0
164
Member Avatar for CPT

I need to implement a function which ads elements to a single linked list: -if the head(first element) of the list doesn't exist(if head is NULL), then the added(inserted) element becomes the head(the the data entered is of string type) -if the head already exists, insert it after the last …

Member Avatar for Ancient Dragon
0
157
Member Avatar for CPT

Hello everyone, I'm not that much of a talker so I'll get straight to the point: I need to implement a hash table in C++, After reading about this topic and algorithms from the book by Cormen, I started to implement it. I wrote it, but it doesn't work how …

Member Avatar for CPT
0
153
Member Avatar for CPT
Member Avatar for maceman
0
61

The End.