No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.
Re:
i have few txt files in one folder. i need a program that will open that folder and read all files one by one to find a string and give me output. so far i got code to do this from only one particular txt file. but i cant make … |
|
Re:
when i do... [ICODE]String menu; Scanner keyboard = new Scanner(System.in); menu = keyboard; if (menu = "D"){ .... }[/ICODE] there is error sign under "menu = "D"" <can't convert String to boolean> why menu is boolean? I stated in String.... |
|
Hello! I was curious if i could help any guidance on my problem. In my program i have the following class. [CODE] class Match{ String File; String Area; int Score = 0; //public Match(int Index ){ public Match(String File,String Area, int Score){ this.Area = Area; this.Score = Score; this.File = … |
|
Hello! I am facing a problem over and would like to ask if anyone knows the solution. On the following code i am looping files for sentences and then words. If a specific word is found i would like to store a String with the specific phrase. In example word[x-3] … |
|
Hello gentlemen. I have a question over here. with the following piece of code i want to extract data from a document. The question is how can i assign the values [B]Sentences, Words[/B] in the Array. [CODE] String data[][]; //[files][sentences][words] public void ScanSearch() { for (int i = 0; i … |
|
Can somebody enlighten me why do i get an exception ? code is over here : [CODE] import java.io.InputStreamReader; import java.util.*; public class ObtainKey { public static void KeyAnalyzer(String input) { int idx = 0; int tokenCount; String inputArr[] = null; StringTokenizer st = new StringTokenizer(input); tokenCount = st.countTokens(); for … |
|
I have a couple of classes in my app. So in one of them i use same int to make my life easier on the other one [CODE] import java.util.*; public class ObtainKey { public static void KeyAnalyzer() { int idx = 0; int tokenCount; String input; String inputArr[] = … |
|
The following code is part of a searchengine the specific piece of code sorts out the different searching options. While running it i get the catch (Exception e) error [CODE] import java.util.*; public class ObtainKey { public static void KeyAnalyzer() { int idx = 0; int tokenCount; String input; String … |
|
Hello there I have a small question. I've been looking on the web for it but didn';t come down with an answer. As far as i've read we can get user input from the console via Scanner [CODE] Scanner asdf = new Scanner(System.in); [/CODE] What if we wanted to analyze … |
|
Hello people. My aim is to assing an array with words read from system.in in a single entry. So if the users enters "Hello there" i will have 0,Hello 1,Therre I have managed to achieve this with the following piece of code. [CODE] import java.util.Scanner; public class mein { public … |
|
It might be quite newbie question but i've been through my books and searched online; yet still didn't find any answers. I have a couple of classes with methods in them. In my main : [CODE] public class main { public static void main(String fileslist[]) { new Folder(); Search SearchFiles … |
|
Hello there I am new to my coding career :) and have been facing a slight problem over here I want to read a folder\s files and have tried countless ways of accessing the directory but keep getting my code's error message. Please have a look and guide me if … |