1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
mote1985 [20]
3 years ago
13

How can I convert a string to a int? in Java

Computers and Technology
1 answer:
Deffense [45]3 years ago
5 0

Answer:

int

Explanation:

You might be interested in
3. Megan and her brother Marco have a side business where they shop at flea markets, garage sales, and estate
Neko [114]

Answer:

a

Explanation:

Megan doesn't have a registered business. She can't claim insurance

4 0
3 years ago
Macro photographs are what type of photographs? A. Close-up B. Telephoto C. Abstract D. All of the above
scZoUnD [109]

Answer:

A

Explanation:

they are close up. they are not telephoto or abstract

marco can be telephoto, but it is not nessacarily always telephoto. marco is by definition a close up photo

5 0
3 years ago
Write a Python program to replace at most 2 occurrences of space, comma, or dot with a colon. Hint: use re.sub(regex, "newtext",
charle [14.2K]

Explanation:

The "re" module in python provides various functions to perform complex string operations easily.

For example, you can check whether a specific word exists in a given string or to replace it with some other word.  

Some of the functions in the re module are:

re.findall

re.search

re.sub()

We are particularly interested in the re.sub() function, we can use this function to replace the occurrences of space, coma or dot with semicolon.  

Syntax:

re.sub(pattern, replace, target_string, n).  

Where pattern = space, coma or dot  

replace = semicolon  

target_string = any string containing spaces, coma and dots

n = number of times you want the replacement to be done  

Code:

import re  

target_string = "Hello world,code,code."  

replace = ":"

pattern = "[ ,.]"

print(target_string)

print(re.sub(pattern, replace, target_string, 2) )

Output:

Hello world,code,code.

Hello:world:code,code.

It replaced the first white space and coma with semicolon, if we increase the n to 4 then the output is

Hello:world:code:code:

As expected, it replaced all of the space, coma, and dots with semicolons.

7 0
4 years ago
Please help me with this question. I don’t get it
IRISSAK [1]

Answer:

d

Explanation:

i took the test

3 0
3 years ago
Read 2 more answers
What controls are available on the ribbon in a contact window
sergij07 [2.7K]

Contact solution is the answer and the work is your brain
8 0
4 years ago
Other questions:
  • How will you be assigned with a mailbox with any OSP
    6·1 answer
  • Uploading is the process of transferring existing content stored on a server or other computer or device to your device via a ne
    8·1 answer
  • Touchdowns were worth 7 points. Braydenand Gavin scored 7 touchdowns. Cole andFreddy's team scored 9 touchdowns. Howmany more PO
    5·1 answer
  • Annalise received financial aid offers from two universities. Financial Analysis for Option A Costs per Year Financial Aid Packa
    8·2 answers
  • Words like "free" or "percent off" will not only trigger spam filters for your email, but will also ___________
    8·1 answer
  • What are the advantages of using an external style sheet?
    9·1 answer
  • Al and Bill are arguing about the performance of their sorting algorithms. Al claims that his O(N log N)-time algorithm is alway
    13·1 answer
  • When a module is processed:
    6·1 answer
  • Which of the following items can you locate in a document using the navigation pane? Choose the answer.
    10·1 answer
  • Write a Python statement that displays the value referenced by the number variable formatted as1,234,567.5
    9·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!