Ashish Dass
BAN USER- 0of 0 votes
AnswersThere is a list of 20 words. 10 of them are good works, and 10 of them are bad words. Write a regex of not more than 25 characters which would tell if given word is good or bad. Input would only contain one of these 20 words.
- Ashish Dass in India
Good words: papa, book, home, cars, jolly, sugar, friend, mother, father, bloomiest
Bad words: ache, slow, torn, slum, boom, rival, wrong, cholera, revenge, arrogant
Input: book
Output: Good
Input: boom
Output: bad
Write Java Code using regex pattern| Report Duplicate | Flag | PURGE
Adobe Java - 0of 0 votes
Answers1. There is a list of 20 words. 10 of them are good works, and 10 of them are bad words. Write a regex of not more than 25 characters which would tell if given word is good or bad. Input would only contain one of these 20 words.
- Ashish Dass in India
Good words: papa, book, home, cars, jolly, sugar, friend, mother, father, bloomiest
Bad words: ache, slow, torn, slum, boom, rival, wrong, cholera, revenge, arrogant
Input: book
Output: Good
Input: boom
Output: bad| Report Duplicate | Flag | PURGE
Adobe Java Developer Java - 0of 0 votes
AnswersJamie is walking along a number line that starts at point 0 and ends at point n. She can move either one step to the left or one step to the right of her current location , with the exception that she cannot move left from point 0 or right from point n. In other words, if Jamie is standing at point i,she can move to either i-1 or i+1 as long as her destination exists in the inclusive range [0,n]. She has a string ,s , of movement instruction consisting of the letters 1 and r , where 1 is an instruction to move one step left and r is an instruction to move one step right.
- Ashish Dass in India for Java
Jamie followed the instructions in s one by one and in order .For Example if s=‘rrlr’,she performs the following sequence of moves :one step right ->one step right ->one step left -> one step right .Jamie wants to move from point x to point y following some subsequence of string s instruction and wonders how many distinct possible subsequence of string s will get her from point x to point y. recall that a subsequence of a string is obtained by deleting zero or more characters from string .
it has four parameters
A String , s giving a sequence of eduction using the characters l( i.e. move left one unit ) and r (i.e. move right one unit)
An integer n, denoting the length of the number line.
An integer x, denoting jamie’s starting point on the number line
An integer y , denoting Jamie’s enidng point on the number line.
The function must return an integer denoting the total number of distinct subsequence of string s that will lead Jamie from point x to point y as this value cab be quite large .
Sample Input
rrlrlr
6
1
2
out put =7| Report Duplicate | Flag | PURGE
Goldman Sachs Java Developer Algorithm - 0of 0 votes
AnswersIn product System , we receive lots of data and in some case data contains duplicate .
- Ashish Dass in India for CRM
In order to process the data correctly we need to identify the row which contains the duplicate .
In this problem , You are receiving data onto 2d Array (m*n ) formate
you and need to find the number of row containing duly data based on on criteria .
Opretaion 1 Return the number of row containing the duplicate data in rows ( minimum count of duplicates can vary ) .
Opreation 2 Retrun the number of rows wherever there are duplicates in the column across the row
(minimum count of of duplicates to consider the row can varry )
if none of the above operating the program will return - 1 .
static int findDuplicates(int[][] data, int operation, int numOfDuplicates) {
}
Example
1,3,5,9
1,2,1,2
1,4,7,9
20,25,20,35
Operation 1 answer = 2
Operation 2 numOfDuplicate=2 then answer = 1| Report Duplicate | Flag | PURGE
Adjetter Media Network Pvt Ltd. Java Developer
RepDiscover the cheapest packers and movers in Gurgaon at best price with smooth and hassle free relocation. We provide truck ...
RepI am Susan From Wasilla USA. and my strong interest in yoga and reading historical books. I have a large ...
RepRoyaltyAd is the top digital marketing company. We have a team of SEO experts that helps you to maximise your ...