# Thread: i need some help please

1. ## i need some help please

Hello everyone, I'm a newbie to this forum, actually, I'm pretty new to all this programming stuffs. I have a little homework problem and I need you helps so .. here it is:

The adjacency matrix for the graph is stored in an array named adjMatrix. The vertices are numbered from 0 to n-1. If an edge exists between vertex i and vertex j by calling edge(i,j). If it returns zero, no edge exists. If it returns something greater than zero then an undirected edge exists between i and j with the weight of the edge equal to the value returned. I need a pseudocode to figure out a way to calculate the degree of each vertex (how many edges are touch it). Then figure out if each degree is even or odd, and count how many even degree vertices and how many odd degree vertices there are. By the way, this is a weighted, undirected graph.

Can anyone give me some advice on how to get this started ?? Thanks alot

2. You can get started by reading this.

3. >I'm pretty new to all this programming stuffs.
>I have a little homework problem
I doubt that you're new to programming and have a homework problem that involves graph theory. You can be either one or the other, but not both. Graphs don't enter into the picture in any curriculum that I'm familiar with until well after you're capable of understanding and implementing them.

4. Originally Posted by Prelude
I doubt that you're new to programming and have a homework problem that involves graph theory. You can be either one or the other, but not both. Graphs don't enter into the picture in any curriculum that I'm familiar with until well after you're capable of understanding and implementing them.
Mmmm... while your likely right, I'm thinking it's possible he could be in the late stages of a non-programming major like mathematics or engineering, where they still require programming courses, they're just more compact. Still, this seems a little advanced for a "new programmer".

5. I am rewlie new at this ... This problem is from my discrete mathematics class ... and so far in that class, I am pretty clueless about all the programming problems. .. I don't need you to do the whole problem for me, I just need a little help on how to get the pseudocode started .... thanks

Popular pages Recent additions