Laborator 04

The english translation

Problem 1:

Scrieti o functie care primeste ca parametru un String si o lista de expresii regulate si returneaza o lista de stringuri care fac match pe cel putin una dintre expresiile regulate primite ca parametru.

Problem 2:

Implementati o Stiva folosind fisiere ca storage.

Problem 3:

Implementati clasa MathOps unde T si G pot fi int, double sau String:

Problem 4:

Implementanti Map<String,dynamic> jsonSubJson(String jsonPath1, String jsonPath2), unde jsonPath1 si jsonPath2 sunt path-uri catre doua fisiere json. Operatia de scadere intre 2 fisiere json ar trebui sa rezulte intr-un json fara nodurile comune. Functia va fi scrisa intr-o librarie separata de cea din care va fi apelata.

English:

Problem 1:

Write a function that takes a string and a list of regular expressions as parameters and returns a list of strings that match at least one of the given regular expressions.

Problem 2:

Implement a Stack using files as storage.

Problem 3:

Implement class MathOps, where T and G can be int, double or String:

    MathOps <T,G> {
      int sub(T obj1, G obj2);
      int prod(T obj1, G obj2);
      int mod(T obj1, G obj2);
    }

Problem 4:

Implement Map<String, dynamic> jsonSubJson(String jsonPath1, String jsonPath2), where jsonPath1 and jsonPath2 are paths to two JSON files. The subtraction operation between the two JSON files should result in a JSON without the common nodes. The function should be written in a separate library from the one where it will be called.