Find Jobs
Hire Freelancers

Small program in java using double queue( must finish it in one day)

$10-30 USD

Completed
Posted about 6 years ago

$10-30 USD

Paid on delivery
implement and use the ADT Double-Ended Queue. The assignment is divided into two parts. In the first part, you will implement the ADT DQueue with an augmented set of operations using linked representation. In the second part, you will write methods that use this implementation: 1. Given the following specification of the ADT DQueue, implement this data structure using linked representation. You should write the class LinkedDQueue that implements the interface DQueue. Specification of ADT DQueue full (boolean flsag): requires: none. input: none. results: if the number of elements in DQ has reached the maximum then ag is set to true otherwise false. output: ag. addFirst (Type e): requires: DQ is not full. input: e. results: Element e is added to DQ as rst element. output: none. addLast (Type e): requires: DQ is not full. input: e. results: Element e is added to DQ as last element. output: none. removeFirst (Type e): requires: DQ is not empty. input: none. results: Removes and returns the rst element of DQ. output: e. removeLast (Type e): requires: DQ is not empty. input: none. results: Removes and returns the last element of DQ. output:e. getFirst (Type e): requires: DQ is not empty. input: none. results: Returns the rst element of DQ. output:e. getLast (Type e): requires: DQ is not empty. input: none. results: Returns the last element of DQ. output: e. length (int k): requires: none. input: none. results: Returns the number of elements in DQ. output: k. reverse (): requires: None. input: none. results: Reverse the order of elements in DQ. output: none. Example 1. If DQ : A; B; C; D; E, then calling [login to view URL]() results in E; D; C; B; A. 2. Write a class called Expr. In this class, you should implement the following static methods: (a) public static DQueue<Character>[] readExpressions(String fileName): A method that reads in x mathematical expressions from a le fileName and builds an array of double-ended queues, where each expression is represented by one DQueue of char-acters. File format: assume that the le fileName consists of a sequence of at most 100 expressions, each one in a separate line and can only contain the following opera-tions: +, -, *, / in addition to the parentheses (, ). For simplicity, assume that the numbers are single digit and unsigned, for instance 5, or 6 but not 23, 124 or -4. An example of in x expression is: 3+(2-1)*7. Assume also that there are no spaces within the expression. (b) public static int evaluateExpression(DQueue<Character>[] dq, int i): A method that evaluates the ith expression in dq and returns the calculated value (all operations, "/" in particular, are considered integer operations). (c) public static boolean reversible(DQueue<Character>[] dq, int i): A method that checks if the ith expression is reversible then it returns true otherwise it returns false. A reversible expression gives the same value if it is evaluated from right to left or from left to right. For example: (5+3)*2 is reversible, but (5+3)/2 is not reversible.
Project ID: 16453385

About the project

10 proposals
Remote project
Active 6 yrs ago

Looking to make some money?

Benefits of bidding on Freelancer

Set your budget and timeframe
Get paid for your work
Outline your proposal
It's free to sign up and bid on jobs
Awarded to:
User Avatar
$20 USD in 0 day
4.9 (50 reviews)
5.6
5.6
10 freelancers are bidding on average $40 USD for this job
User Avatar
I am a full time developer and have greate skills in java, javafx, java swing so I can complete this project. My price and time is negotiable. Let's discuss details via chat. I'll provide best service.
$100 USD in 1 day
5.0 (325 reviews)
7.9
7.9
User Avatar
Hello Sir/ Ma’am We are a group of Software Engineers having 10+ years of experience. Expert in java, C, C++ , C# , Android. Please check our profile for reference. Thank you
$25 USD in 1 day
4.9 (359 reviews)
7.6
7.6
User Avatar
Hey A Java expert developer is here I have good advanced expertise in java and Javafx This is an initial bid I can write a program for you as per your need Feel free to message me regards
$20 USD in 0 day
4.9 (224 reviews)
6.8
6.8
User Avatar
Hello sir I can do it.I went carefully through your requests and I think it is ideal for me and my abilities.
$88 USD in 1 day
4.9 (27 reviews)
4.7
4.7
User Avatar
السلام عليكم انا مبرجم جافا محترف و سوف اكون سعيدا جدا لمساعدتكم انا متاح الان للعمل لذلك برجاء التواصل للحصول علي اتفاق شكرا لتواصلكم
$30 USD in 1 day
5.0 (23 reviews)
4.7
4.7
User Avatar
Strong experience in JAVA software programming High ability to identify and implement process improvements Thorough understanding of Object-Oriented software development and formal development methodologies
$25 USD in 0 day
5.0 (6 reviews)
3.1
3.1
User Avatar
A proposal has not yet been provided
$10 USD in 2 days
3.6 (33 reviews)
4.0
4.0
User Avatar
A proposal has not yet been provided
$55 USD in 1 day
4.8 (2 reviews)
2.7
2.7

About the client

Flag of SAUDI ARABIA
Riyadh, Saudi Arabia
5.0
4
Payment method verified
Member since Nov 2, 2017

Client Verification

Thanks! We’ve emailed you a link to claim your free credit.
Something went wrong while sending your email. Please try again.
Registered Users Total Jobs Posted
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
Loading preview
Permission granted for Geolocation.
Your login session has expired and you have been logged out. Please log in again.