CMPT 125 Study Guide - Final Guide: Regular Expression

87 views2 pages

Document Summary

Draw a dfa that accepts all strings that contain aab , and rejects all other strings. Draw a dfa that rejects all strings that contain aab , and accepts all other strings. Describe the language expressed by the following regular expressions. Let f(n) and g(n) be two functions on positive integers. f = o(g) will mean that f is essentially smaller than g. Wrong definition: f = o(g) if f(n) <= g(n) for all n. Wrong definition 2: f = o(g) if f(n) <= 2g(n) for all n. Then, we want f = o(g), but it is not true that f(n) <= g(n) for all n. Correct definition: we say that f = o(g) if there exists a large enough constant c (e. g. c = 1000) such that f(n) <= c*g(n) for all n. Write a function to determine whether an expression is legal.

Get access

Grade+20% off
$8 USD/m$10 USD/m
Billed $96 USD annually
Grade+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
40 Verified Answers

Related Documents

Related Questions