Yes here's the output:
The order of the graph = 6
The size of graph = 14
Graph:
Index 0: 0,2
Index 1: 0,4
Index 2: 1,4
Index 3: 1,5
Type: Posts; User: custurd122000
Yes here's the output:
The order of the graph = 6
The size of graph = 14
Graph:
Index 0: 0,2
Index 1: 0,4
Index 2: 1,4
Index 3: 1,5
I'm trying to read a text file of a graph and print information about the graph including the order and size of the graph, rather it is a directed or undirected graph, if it is directed the in and...
I have this code for reading a text file and printing out information about the graph, the program works perfectly but I need to figure out the in degree and out degree of the graph if it is an...
Oh okay I see, so how would I call my insert method?
I'm having a problem implementing double hashing when I insert a value into the table i get this for the output:
Insert []. Is there something I'm doing wrong? I'm not getting any errors
...
You were right, i inputted the algorithm incorrectly...now the data file in case 2 is still posting incorrectly, heres the updated algorithm
{
public static int maxSum(int[] a, int n)
...
I'm not supposed to change that algorithm, I can only change the case statements that call upon it
No you were correct it should be 1 but its printing out 7, the code just prints out the sum you had the correct idea but when adding negatives it warps the result into a strange result
In theory yes it should but the result of that is actually 7??? I have no clue where the numbers are coming from but
1,2,3,4,5,6 prints out 21
The maxSum is given the problem is the implementation of it but what it is is basically an algorithm that prints out the sum of the
integer array. It works as is but it won't let me input negative...
How would I go about inputting the negative values in the array in case 1 the array comes from the user, case 2 from the text file?
The sum prints perfectly fine with positive values but if I input...
I need to implement a separate-chaining hash table from scratch and I don't need to know the code or anything
I would just like an explanation of how I would go about doing the algorithm for this...