Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

How do i read fractions off a string input in java? i want the user to input a string of fractions say 13/3 3/2 3/8

How do i read fractions off a string input in java?

i want the user to input a string of fractions say

\"13/3 3/2 3/8 12/5 4/5\"

i want to read these fractions and store them into an array int if possible, and get the total count of fractions inputed.

in this case count = 5

array[0] = 13/3

or array[0] =13 array[1]=/ array[2] =3

i'm not sure.. i'm kinda lost..

please show me in code

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Pro Android Graphics

Authors: Wallace Jackson

1st Edition

1430257857, 978-1430257851

More Books

Students also viewed these Programming questions

Question

Would giving rewards or administering punishments be

Answered: 1 week ago