How do you add a numerical value to a regex

How do you add a numerical value to a regex

how do you add a numerical value in a regex. I want to replace my pics ex: bob.jpg susan.jpg mike.jpg with 1.jpg 2.jpg 3.jpg etc. Thanks

View Answers

June 6, 2013 at 5:45 PM

hi friend,

Split the file name using the following regex

String regex = "\\.";

and then replace the file name with the numbers as you required.

Thanks.









Related Tutorials/Questions & Answers:
How do you add a numerical value to a regex
How do you add a numerical value to a regex  how do you add a numerical value in a regex. I want to replace my pics ex: bob.jpg susan.jpg mike.jpg with 1.jpg 2.jpg 3.jpg etc. Thanks
How do you pass a variable by value?
How do you pass a variable by value?  How do you pass a variable by value
Advertisements
How do you do data mining projects?
How do you do data mining projects?  Hi, I am beginner in Data... do you do data mining projects? Try to provide me good examples or tutorials links so that I can learn the topic "How do you do data mining projects
How do you define a constant?
How do you define a constant?  How do you define a constant in php
How do you sum a dictionary
How do you sum a dictionary  Hi, I want to sum the values of two dictionary based on keys. How do you sum a dictionary
How do you call a constructor for a parent class?
How do you call a constructor for a parent class?  How do you call a constructor for a parent class
how do you parse by reference in java(with JGrasp)
how do you parse by reference in java(with JGrasp)  i am a 1st year beginner in java programming(GR 10) at hillcrest High School in south Africa My question is how do you parse by reference in java(with JGrasp) please help me i
How do you master python in a month?
How do you master python in a month?  Hi, I am beginner in Data...: How do you master python in a month? Try to provide me good examples or tutorials links so that I can learn the topic "How do you master python in a month
How do you get the size of an array in Python
How do you get the size of an array in Python  Hi, I want to get the size of my array in Python. How do you get the size of an array in Python? How... array you can use len() function. The len() function takes array an argument
Are you a self-made data scientist? How did you do it?
Are you a self-made data scientist? How did you do it?  Hi, I am... for the tutorials to learn: Are you a self-made data scientist? How did you do it? Try...;Are you a self-made data scientist? How did you do it?". Also tell me
How to add key value pair in Java
How to add key value pair in Java  Hi, I have to store the key and value pair in Java. How to store key value pair in Java? Thanks   Hi, You can use the put method of Hashtable. Check the tutorial Creating a Hash
How do you map Java Objects with Database tables?
How do you map Java Objects with Database tables?  Hi, How do you map Java Objects with Database tables? thanks
you pass a variable by value.
you pass a variable by value.  How do you pass a variable by value... $a = &$b /*--------------Pass By value----------------*/ function add($a) { return ++$a; } add($a); /*---------------Pass by reference
How to add value from sql server in dropdownlist
How to add value from sql server in dropdownlist  I have created a hospital management project using jsp servlet, where one form name is patient registration, in that form i have taken id, name, and i want to retrieve a patient
how do you change the message box to a specific color
how do you change the message box to a specific color  How do you change the message box color to a specific color? I can get the color to change... the message box to red but its not really working. Can you help me
RegEx
RegEx  I want to know the javascript RegEx code for validation of ( ) parenthesis.. The code is validating the parenthesis but after submit the parenthesis is disappear. what should i do
How do you combine two dictionary values for common keys
How do you combine two dictionary values for common keys  Hi, I have... be:: final = {"a":500, "b":500, "c":1300} How to combine values in a new dictionary? I want example code in Python. How do you combine two dictionary values
How do you make a Jarvis like AI in Python?
How do you make a Jarvis like AI in Python?  Hi, I am beginner... to learn: How do you make a Jarvis like AI in Python? Try to provide me good examples or tutorials links so that I can learn the topic "How do you make
What do you mean by Deadlock?
What do you mean by Deadlock?  What do you mean by Deadlock
How would you read in and add all this into a list?
How would you read in and add all this into a list?   FYI this is all stacked. 0 " " " " " " " " " " 1 "48" "111" "Dallam" "06" "County" 2 "48" "421" "Sherman" "06" "County" 3 "48" "295" "Lipscomb" "06
how to do this?
how to do this?   Given any integer 2D array, design then implement a Java program that will add to each element in the array the corresponding column number and the corresponding row number. Then, it prints the array before
What do you understand by JPA?
What do you understand by JPA?  What is JPA and how it can be integrated? Thanks   Hi, Check at JPA 2.1 Tutorial. Thanks
in an application one task has to done for every 15 minutes ? How con you do it?
in an application one task has to done for every 15 minutes ? How con you do it?  in an application one task has to done for every 15 minutes ? How con you do
How to find the first 6 characters of string in regex?
How to find the first 6 characters of string in regex?  How to find the first 6 characters of string in regex. I know the Syntax...(0,7)); But i need the syntax to find the first 6 characters of string in regex
How to add radio button value in a table for particular field?
How to add radio button value in a table for particular field?  Hi,I... one radio button for text field then it insert only one value absent OR present...() { if(doucment.getElementById(elementId)) document.getElementById("pre").value
Maven, Gradle, SBT, Ivy, Grape, Leiningen and Buildr Dependency for Regex version 1.0.0
Maven, Gradle, SBT, Ivy, Grape, Leiningen and Buildr Dependency for Regex version 1.0.0. You can add these depency in your project to get com.techshroom:Regex... and  Buildr Dependency for Regex version 1.0.0. You be able to use
Maven, Gradle, SBT, Ivy, Grape, Leiningen and Buildr Dependency for Regex version 1.0.0
Maven, Gradle, SBT, Ivy, Grape, Leiningen and Buildr Dependency for Regex version 1.0.0. You can add these depency in your project to get com.techshroom:Regex... and  Buildr Dependency for Regex version 1.0.0. You be able to use
What do you mean by Serialized?
What do you mean by Serialized?  What do you mean by Serialized?   Hi, It is the part of the isolation level , Its bassically use for the Data read by the current transaction cannot be changed by another transaction
How to delete line starting with a letter in java Regex?
How to delete line starting with a letter in java Regex?  Hi, i 'm trying to code with regex and java. i want to know how it's possible to delete lines which starts with a letter like G or g in a text. i tried
Do you need math for AI?
Do you need math for AI?  Hi, I am beginner in Data Science and machine learning field. I am searching for the tutorials to learn: Do you need... learn the topic "Do you need math for AI?". Also tell me which
What do you learn in AI?
What do you learn in AI?  Hi, I am beginner in Data Science and machine learning field. I am searching for the tutorials to learn: What do you... learn the topic "What do you learn in AI?". Also tell me which
ModuleNotFoundError: No module named 'marshmallow-numerical'
: No module named 'marshmallow-numerical' How to remove the ModuleNotFoundError: No module named 'marshmallow-numerical' error? Thanks   Hi...ModuleNotFoundError: No module named 'marshmallow-numerical'  Hi
ModuleNotFoundError: No module named 'Numerical-CFS'
'Numerical-CFS' How to remove the ModuleNotFoundError: No module named... environment you have to install padas library. You can install Numerical-CFS python...ModuleNotFoundError: No module named 'Numerical-CFS'  Hi, My
ModuleNotFoundError: No module named 'numerical-z'
'numerical-z' How to remove the ModuleNotFoundError: No module named '... you have to install padas library. You can install numerical-z python...ModuleNotFoundError: No module named 'numerical-z'  Hi, My Python
ModuleNotFoundError: No module named 'Numerical-CFS'
'Numerical-CFS' How to remove the ModuleNotFoundError: No module named... environment you have to install padas library. You can install Numerical-CFS python...ModuleNotFoundError: No module named 'Numerical-CFS'  Hi, My
ModuleNotFoundError: No module named 'numerical-z'
'numerical-z' How to remove the ModuleNotFoundError: No module named '... you have to install padas library. You can install numerical-z python...ModuleNotFoundError: No module named 'numerical-z'  Hi, My Python
ModuleNotFoundError: No module named 'scikit-numerical'
named 'scikit-numerical' How to remove the ModuleNotFoundError: No module named 'scikit-numerical' error? Thanks   Hi, In your...ModuleNotFoundError: No module named 'scikit-numerical'  Hi, My
ModuleNotFoundError: No module named 'scikit-numerical'
named 'scikit-numerical' How to remove the ModuleNotFoundError: No module named 'scikit-numerical' error? Thanks   Hi, In your...ModuleNotFoundError: No module named 'scikit-numerical'  Hi, My
How can you add elements of two arrayLists in java?
How can you add elements of two arrayLists in java?  if you have... of tempArray2 = [a, b, c, d, e] and you want it to result in newArr = [hi a, my b, name c, is d, john e] how do you go about
Maven, Gradle, SBT, Ivy, Grape, Leiningen and Buildr Dependency for regex-tester version 0.4
-tester version 0.4. You can add these depency in your project to get com.thewonggei..., Leiningen and  Buildr Dependency for regex-tester version 0.4. You... which you use to manage your project and easily use regex-tester version 0.4
Maven, Gradle, SBT, Ivy, Grape, Leiningen and Buildr Dependency for regex-tester version 0.1
-tester version 0.1. You can add these depency in your project to get com.thewonggei..., Leiningen and  Buildr Dependency for regex-tester version 0.1. You... which you use to manage your project and easily use regex-tester version 0.1
Maven, Gradle, SBT, Ivy, Grape, Leiningen and Buildr Dependency for bytes-regex version 0.0.1
version 0.0.1. You can add these depency in your project to get com.tmiyapub..., Leiningen and  Buildr Dependency for bytes-regex version 0.0.1. You... tool which you use to manage your project and easily use bytes-regex version
ModuleNotFoundError: No module named 'regex'
' How to remove the ModuleNotFoundError: No module named 'regex'... padas library. You can install regex python with following command: pip...ModuleNotFoundError: No module named 'regex'  Hi, My Python
What do you mean by docker container
What do you mean by docker container  Hi, I want to know more about Docker container. How to use this for running my projects? Can any one tell me what do you mean by docker container? Thanks
What do you understand by private, protected and public?
What do you understand by private, protected and public?   Hi, What do you understand by private, protected and public? thanks
How will you add panel to a frame? - Java Interview Questions
How will you add panel to a frame?   How will you add panel to a frame?   you can simply use add method to add panel to a frame i.e panelA.add(frameA)  Hi Friend, Using add() method of JFrame. import
ModuleNotFoundError: No module named 'kr_numerical_analysis'
: No module named 'kr_numerical_analysis' How to remove the ModuleNotFoundError: No module named 'kr_numerical_analysis' error? Thanks   Hi...ModuleNotFoundError: No module named 'kr_numerical_analysis'  Hi
ModuleNotFoundError: No module named 'Numerical-CFS-Cluster'
: No module named 'Numerical-CFS-Cluster' How to remove the ModuleNotFoundError: No module named 'Numerical-CFS-Cluster' error? Thanks   Hi...ModuleNotFoundError: No module named 'Numerical-CFS-Cluster'  Hi
ModuleNotFoundError: No module named 'Numerical-CFS-Cluster'
: No module named 'Numerical-CFS-Cluster' How to remove the ModuleNotFoundError: No module named 'Numerical-CFS-Cluster' error? Thanks   Hi...ModuleNotFoundError: No module named 'Numerical-CFS-Cluster'  Hi
ModuleNotFoundError: No module named 'Numerical-CFS-Cluster'
: No module named 'Numerical-CFS-Cluster' How to remove the ModuleNotFoundError: No module named 'Numerical-CFS-Cluster' error? Thanks   Hi...ModuleNotFoundError: No module named 'Numerical-CFS-Cluster'  Hi

Ads