3,815 Topics
![]() | |
Yes I know its a long code and it will get longer but there is a compiler error in the [COLOR="Green"]int main ()[/COLOR] First Visual C++ 2008 Express edition error [QUOTE] ------ Build started: Project: MAC ADDRESS, Configuration: Debug Win32 ------ Compiling... MAC ADDRESS.cpp warning C4603: '_WIN32_WINNT' : macro is … | |
Hi i have created this thread for general information of Google.....!! Can anyone tell me how does Google works, I want to know the algorithm that works behind that, i mean how the Google search is working. Can anyone give me the idea regarding this............... Every answer is appreciated......... | |
I think I have to the code right cuz it all compiles perfectly except when its done running, and I go to my documents, I dont see my directory... [code] #include <iostream> #include <windows.h> #include <winuser.h> #include <stdlib.h> #include <string> #include <stdio.h> #include "stdafx.h" #include <lm.h> #include <assert.h> #include <fstream> … | |
I have to manipulate strings so that, we need to check if a string needs to be combined with another string. Need to use a library function for this. Suppose, we have S1. This is an apple s2. apple is sweet so, the combined line should be: This is an … | |
Hello, Could anybody please help me understand the idea of LCR leader election in a synchronous ring? The idea is: Suppose a distributed system consists of a collection of homogeneous participants • How to pick one out of this group? Basic assumptions • Each participant has a unique identifier • … | |
Ok the code below is supposed to edit a file called license.dat and replace texts in it... it works great it does all that but I want to implement user input in it. By this I mean I want the user to be able to enter the drive letter for … | |
Hello, i am a final year student in engineering and my project require me to write an algorithm to solve a puzzle problem.Actually, my project is on a 3x3 warehouse space where items need to be stored and retrieved.how do i get started with writing the algorithm? i already made … | |
I'm writing a collision algorithm based on the Separating Axis Theorem that works like so for each side: - Gets the separating axis of the side - Measures the object's width on that axis and places the width on the axis. - Measures/places width for object that is being collision-tested. … | |
Hi, I have found this code that helps me convert the bearing and distance in to latitude and longitude. Lat/lon given radial and distance A point {lat,lon} is a distance d out on the tc radial from point 1 if: [CODE] lat=asin(sin(lat1)*cos(d)+cos(lat1)*sin(d)*cos(tc)) IF (cos(lat)=0) lon=lon1 // endpoint a pole ELSE … | |
I have a new assignment about Huffman encoding, there is part of the assignment that is not clear to me, I searched the web, but could not find an answer, I need some help to understand this part. it is as follows: The standard algorithm states that you should use … | |
hi all, I write this program under the C++ not C. But I heaively used the malloc() and free() functions in my code. In brief what my code does is just allocate memory for NFA transition table. It grows dynamically. When the number of transitions is a %4 then it … | |
Can someone help me please, I am getting this error: [B]stringdefinition.cpp(7) : error C2448: 'stringClass::wordCount' : function-style initializer appears to be a function definition[/B] When trying to compile this code: [B][U]StringHeader.h[/U][/B] [CODE] #ifndef H_StringHeader #define H_StringHeader #include <iostream> #include <string> #include <cstring> #include <algorithm> using namespace std; const int strLength … | |
guys wondering how come the code doesnt work.. im using tasm as u might know..im checking on things work and want to see what its output be..thanks hope you can help me with this one. i tried converting it tasm but say argument needs to be override. [code] .model small … | |
Hi Everyone, So i have been trying to figure this out for ages. Im just not able to to get the algorithm straight. Say I am given a string containing markup tags ex. <html> </html> in a string like this: <html> <head> <title> Example </title> </head> <body> quiet <CAPSLOCK> LOUD … | |
I read an algorithm on collaborative clustering and the author is merging and splitting for the same side of the threshold. Is it right to do so? | |
My understand is in generic programming you can have multiple containers, which use iterators but use the same algorithm. Wouldn't template be considered a ADT? Really confused. | |
Does the search algorithm use the current contents of the database, or a snapshot? Because I can do a search for something I know exists in a recent thread, but it doesn't show up in the results. | |
Hello Can you assist me in developing my algorithm? I have to do this: [QUOTE]Write a C++ function balanced that uses a [B]stack[/B] to check that all brackets in a string are balanced. For eg: This is a balance string: [I]This (string) has (balanced {brackets[(now)]} [thanks])[/I] This string is not … | |
Okay, I was thinking about making an encryption algorithm, now the thing with most algorithms is that they follow specific steps. Well, I was thinking, what if you made an algorithm that generated random characters (the kind you see on your keyboard, excluding characters that could crash the program), and … | |
Hi I am trying to find out a way to swap two nodes in an unordered linked list. I want to find out a way where i can change the links of the two nodes so they are swapped. I know I am supposed to use the previous and next … | |
[QUOTE=varunrathi;72258]Can anybody help me with permutation in c++. say if the entered string is "stop" then there must be 24 (=4*3*2*1) different words made by the letters s,t,o,p. Similarly if the entered string is "abcde" then there will be 120 (=5*4*3*2*1) different words made using the letters a,b,c,d,e. Please Help. … | |
Hi, I am thinking about something that I heard in a discussion and I am not sure whether it is really like that or not. Calculating a shortest path on a graph can be done either using dijkstra's algorithm , basically DFS or by BFS. There might be some other … | |
[CODE]ok ok i got it now right i copy it to vector and sort it..... here is the code #include <iostream> #include <fstream> #include <algorithm> #include <string> #include <map> #include <vector> using namespace std; typedef map<string,int> word_count_list; struct val_lessthan : binary_function < pair<string,int>, pair<string,int>, bool > { bool operator() (const … | |
ok ok i got it now right i copy it to vector and sort it..... here is the code #include <iostream> #include <fstream> #include <algorithm> #include <string> #include <map> #include <vector> using namespace std; typedef map<string,int> word_count_list; struct val_lessthan : binary_function < pair<string,int>, pair<string,int>, bool > { bool operator() (const … | |
.the program is running .display the frequency of words and sort them from highest count to lowest. my problem is about the duplication of the counts or value of the words.if the value of the word are same it only display the first word&value ...can some one help here is … | |
I want the following. Write a program that implements the FIFO and LRU page-replacement algorithms ( Virtual Memory) 1) Read the size of reference string from keyboard 2) Generate a random page-reference string where page numbers range from 0 to 9 3) Create a input file with generated reference string … | |
Hey guys need some help with this. I m kinda new to c++. I m trying to insert a structure into a set. and when i compile this i m a gettin an error. i guess i need to add a comparator function please let me how do i do … | |
hi pple.... i am doin a mini proj and can anyone please help me the java code of the ad-hoc on distance vector routing algorithm..... | |
Hello Good people,am not so sure if this should go here,i am student who is interested in developing a search engine that indexes pages from my country.I have been doing my research on Algorithm to use for sometime now and i have found HITS and PageRank as the best out … | |
Hi, i have created a program in c++ that implements dijkstra's algorithm, and i would like to count how many operations the program makes, but i dont know how. Here is my main code: int main() { int counter =0; dij d; d.read(); d.algorithm(); d.output(); return 0; } can anyone … | |
I'm running into an issue with a program. I need a method that takes a string and returns every possible combination of upper and lower case letters for that string. For instance, cat would return: cat caT cAt cAT Cat CaT CAt CAT The string entered could be any length … | |
Hello, I'm posting this code so that maybe it will help someone else in the future. I spent about a week trying to figure this out, and Google searches were not helping. Hopefully anyone else wondering about this will see this post on a Google result. The program I finished … | |
please i want the source code of CPU scheduling algorithm ( FCFS, SJF, priority ) in C language send at [email]samighoul@yahoo.com[/email] thank yooooooooooooou very much :sad: | |
Hey guys, I have written a recursive function mazeTraverse which finds the path of the mouse to find its food which is placed inside the maze. I am given a maze of of 15 rows and 25 columns. Mouse's starting position is (8,1)[eighth row and 1st column] and the food … | |
Hi good day. i am designing a little project for school. This project is to register the MAC address of the laptops of every student in the school. My problem is, when i put in the student's MAC address in the textbox, i would like the little search algorithm i … | |
The following is the randomized Binary search tree insertion algorithm mentioned in sedgewick's book. "This function makes a randomized decision whether to use the root insertion method of Program 12.13 or the standard insertion method of Program 12.8. In a random BST, each of the nodes is at the root … | |
I'm in the process of writing a 2D physics engine in Java, and am trying to figure out the algorithm for the most basic of all physics tasks: Object collision. Detecting collision between two circles is easy: check if the distance between their centers is less than or equal to … | |
[ICODE] #include <iostream> #include <algorithm> #include <string> using namespace std; struct employees { int em_id; string em_name; string position; string gender; }; void read(employees record[], int max_1); bool IDsort(const employees &a, const employees &b) { return(a.em_id < b.em_id); } char Namesort(const employees&a, const employees &b) { return(a.em_name < b.em_name); } … | |
guys i need an error-free way of keeping name value pairs in a regular c# string. i am quite busy, i dont think i am able to come up with the best algorithm now. what i want is two methods one to add a name-value pair to the string, the … | |
hiii Im searching for a method or an algorithm that can help me in finding number of holes in an image this image is basically for a letter like "D" "B" --->number of holes can distinguish between those letters.. this will help me alot in my project if it works … | |
Hi, i need help in building a program about automata cellular. So, there is 4 state of cells, `0 = space, 1 = ".", 2 = "+", 3 = "#"` This state is continuous from 0 - 3, after 3, it will be back to 0. we need to compare … | |
(Credit card number validation) Credit card numbers follow certain patterns. A credit card number must have between 14 and 16 digits. It must start with: • 4 for Visa cards • 5 for Master cards • 37 for American Express cards. • 6 for Discover cards In 1954,Hans Luhn of … | |
[CODE]#include <iostream> #include<vector> #include<ctime> #include<algorithm> using namespace std; struct student { int id; char name; char nationality; char gender; student() : id(0) , gender(' ') { } student(int i, char g) :id(i), name(g) { } }; void insert(student array[]); bool sortByID(const student& a, const student& b) { return ( a.id … | |
I'm working on this problem that has n positive integers in a row except for the first column, which always contains zero, these numbers represent the cost to enter each column. I'm supposed to get to the end of the board with the path that costs the least. I can … | |
hi i want to get it's implementation as soon as possible. i will be thankful for your help. :icon_redface: | |
Hi thr, I'm Jega, doing a project on data preprocessing using discretization(data mining methods). There is an algorithm called EFB(Equal Frequency Binning) using C++ as coding. Do any1 here familiar with machine learning. I got the algorithm, but coding part, i just too weak in tht. | |
[QUOTE=tatumkay;313662]just started c++ class.... we use the absolute c++ book after starting to read this book i decided to buy c++ for dummies and borrowed a book titled object oriented programming with c++ (book is from india written in english) i still have no idea where to start on these … | |
I have been bashing away at this for hours and am not making any new ground. I have to find the employee that is closest to the all the average. Originally I thought I would just see how far each value was away from the average (eg ageRemainder = averageAge … | |
The meaning of parallel is not that of parallel processing. I simply mean that if algorithms A and B are represented by the two sequence of operations (a_1, a_2, ...) and (b_1, b_2, ...), then the executed sequence of operations is (a_1, b_1, a_2, b_2, ...). It is not compulsory … | |
This is actually a quiz in our Algorithm Analysis and Design class where we're provided a 9x9 sudoku table filled with few numbers. Now, our teacher allowed us to use any programming language, provided that it's [b]structural[/b] and not OOP, in order to come up with a sudoku solver app. … |
The End.