Question
in java, here is what include in the text file INT x ; READ( x , A . i n p u t ) ;
in java,
here is what include in the text file
INT x ;
READ( x , A . i n p u t ) ;
INT y ;
READ( y , B . i n p u t ) ;
here is the thing, i use a method to scan everying in the text file, character by character into a string, if its not a character or degit, ignore it and continue.
String[] keyword ={"INT","READ"}
i use
if (!keyword.contains(token))
to check if its a token, the token should be x, y
it also need to ignore everything between 2 quotation marks, but i dont know how to do that, so i end up including B, input, A, output as tokens.
what should i do to ignored that?
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started