Is it possible to create a regular language from an non regular language?

I am wondering if it is possible to create a regular language from a irregular language if we add or remove finite number of words from it?

say L is irregular, can we add or remove finite number of words to create a regular language?

i might be mistaken, but since all regular languages are finite - if we add a finite amount to a non regular language - it still stays non regular, but if we substract, let's say a finite amount from infinity, it is still infinity.

so is it safe to say that in both cases a regular language cannot not be obtained by adding/substracting a finite amount of words?

• This question might be a better fit for Computer Science, but consider expressing your question more formally first. E.g. you want to “add or remove a finite number of elements” – what is an element here? A word w in the language L? And what precisely do you mean by a non-regular language? Something like context free or recursively enumerable languages (i.e. the enclosing sets of languages in the Chomsky hierarchy)?
– amon
Dec 2 '18 at 14:44
• Note that looking at this problem in reverse might be simpler: can adding a finite number of words w1, w2, … wn to a regular language L make that language non-regular? No, the resulting language is still regular. The language could e.g. be described with the regular expression `w1|w2|...|wn|R` where R is a regular expression describing the original language L. The question whether removing a number of words from a regular language keeps the language regular is more difficult, but I think it could be proven by using an NFA.
– amon
Dec 2 '18 at 14:49
• thank you very much for your comment - i am in the beginning of the course and we have not yet encountered chomsky hierarchy. by element i meant words, and i will correct that in an edit Dec 2 '18 at 14:50
• i didn't understand the second comment quite well. the question is about adding/substracting a finite amount of words from a non regular language, i.e if we add/substract a finite amount of words from a nonr regular language - can make it regular? and i think that the answer is no Dec 2 '18 at 14:54
• thank you for your comment akiva, but this is the term that is regularily being used in automata theory: regular and non regular languages. even why i searched in google and similar sites before asking the question, all were using the same terminology Dec 2 '18 at 15:30