Write easy java snippet code

I gang Opslået 6 år siden Betalt ved levering
I gang Betalt ved levering

Questions: Understand the code snippet below and do as instructed in ‘TODO’ section.

Code Snippet:

a = [1,2,3,4,10,20,30] # random length between 1 to 10,000, random content 1 to 10,000

b = [20,30,1,2,1,3,4,4,5]

def mergeCounter(a,b):

response = {}

# Rules:

# modify of array a and b is not allowed

# merge of a and b is not allowed

# you can only use one loop

###

# TODO: Implement this function in below section

###

# Output:

# Key: number

# value: frequency of key from array a and b

# Example:

# a = [1,2,1,5]

# b = [1,3,3,4,5]

# response = {1:3,2:1,5:2,3:2,4:1}

return response

# Testing

mergeCounter (a,b)

Coding Google Maps API Software Arkitektur Software Udvikling Testning / QA

Projekt ID: #16040873

Om projektet

3 bud Remote projekt Aktiv 6 år siden

Tildelt til:

$20 USD på 1 dag
(2 bedømmelser)
1.6

3 freelancere byder i gennemsnit $30 timen for dette job

algispetkuns

can do this for you Relevant Skills and Experience with one loop Proposed Milestones $40 USD - completed and tested

$40 USD på 1 dag
(27 bedømmelser)
5.1