Build a hash table using chaining as the collision resolution technique

Concluído Postado Apr 22, 2015 Pago na entrega
Concluído Pago na entrega

Program Specification:

Build a hash table using chaining as the collision resolution technique. Insertions into the hash table will correspond to declarations of variables and values in a program, searches will be requests for the value of a variable. Some variables will be local and have a narrow scope while some variables will be global.

The program will take input from a file, another program written in the omnipotent programming language BORG (Bionicly Omnipotent Resistance Grinders) and generate output from this program.

The BORG language has the following commands (keywords):

1. START-FINISH blocks. Indicating different scopes.

2. COM - Single line comments: Text should be ignored if on the same line

3. VAR varName – Variable Declaration, adds “varName” to the hash table.

4. variable = expression – Assignment statements, ie GEORGE = 122. Find GEORGE in the hash table and assign 122 to it.

5. ++ - increment operator, syntax: VARIABLE ++

6. -- - decrement operator, syntax: VARIABLE --

7. expressions, expressions are limited to unary and binary arithmetic, or variable names

8. supported operators: + - / * % ^ (plus, minus, divide, multiple, modulo, exponent)

9. PRINT – syntax PRINT expression. If the expression is a variable, and this variable is not in scope, then an error message indicating unknown variable x at line number y. The value printed if there is a variable in scope should be the variable with the closest scope.

10. Errors – other than the print statements, our interpreter will not be responsible for detecting errors, syntax errors should be disregarded if encountered, assume that the source file is correct.

Our hash function: sum the ordinal values of the characters of the variable multiplied by their position in the string (1-indexing), then taking the modulo by TABLESIZE.

Programação C Programação C++

ID do Projeto: #7536365

Sobre o projeto

5 propostas Projeto remoto Ativo em Apr 23, 2015

Concedido a:

it2051229

Hi, I have read the requirements and I would like to do this project if given the opportunity. I am a computer science practitioner and having the "C++ and Algorithms Certification Badge" in my profile gives me confide Mais

$50 USD em 1 dia
(315 Comentários)
6.4

5 freelancers estão ofertando em média $115 nesse trabalho

hbxfnzwpf

I am very proficient in c, c++. I have 15 years c++ developing experience now, and I have worked for 5 years. My work is online game developing, and mainly focus on server side, the language is c++ under linux. I used Mais

$80 USD in 3 dias
(74 Comentários)
6.3
jaynanavati

Hi...A Sun certified Java Porgrammer here with expertise in Data Structures using C/C++. I've been teaching Data Structures using C/C++ to PG/UG students since last 11 years.

$155 USD in 3 dias
(0 Comentários)
0.0
pipah

I can program in C, C++ Final Year CS student I learned about Hashing in Algorithm class, so I understand the basic Since you have your own command, I'd figure, I can just follow your instructions

$155 USD in 3 dias
(0 Comentários)
0.0
sachin1301

A proposal has not yet been provided

$133 USD in 3 dias
(0 Comentários)
0.0
shylett11

Hello Sir.. Before hiring someone, check completion rate and portfolio from profile www.freelancer.com/u/shylett11.html I am an independent and professional developer. Quality is guaranteed. My completion rate is al Mais

$155 USD in 3 dias
(3 Comentários)
0.0