Programming > Research Paper > Irvine Valley CollegeCS 41CS41Assignment4.java (All)

Irvine Valley CollegeCS 41CS41Assignment4.java

Document Content and Description Below

/* 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. 1... . START­FINISH blocks. Indicating different scopes. 2. COM ­ Single line comments: Text should be ignored if on the same line 3. VAR varName varName 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 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. */ package cs41.assignment4; import java.io.File; import java.io.FileNotFoundException; import java.util.Hashtable; import java.util.Scanner; /* */ public class CS41Assignment4 { static int TABLESIZE = 37; /*Intialize an array size of 37*/ static int Hashing(String chars) { int hash = 0; for (int i = 0; i < chars.length(); i++) { hash += chars.charAt(i) * (i + 1); } return hash % TABLESIZE; /* return the index in the hash table */ } public static void main(String[] args) throws FileNotFoundException { [Show More]

Last updated: 1 year ago

Preview 1 out of 9 pages

Reviews( 0 )

$9.00

Add to cart

Instant download

Can't find what you want? Try our AI powered Search

OR

GET ASSIGNMENT HELP
60
0

Document information


Connected school, study & course


About the document


Uploaded On

May 20, 2021

Number of pages

9

Written in

Seller


seller-icon
Muchiri

Member since 3 years

208 Documents Sold


Additional information

This document has been written for:

Uploaded

May 20, 2021

Downloads

 0

Views

 60

Document Keyword Tags

Recommended For You

What is Browsegrades

In Browsegrades, a student can earn by offering help to other student. Students can help other students with materials by upploading their notes and earn money.

We are here to help

We're available through e-mail, Twitter, Facebook, and live chat.
 FAQ
 Questions? Leave a message!

Follow us on
 Twitter

Copyright © Browsegrades · High quality services·