For each of the following signatures, create a function that will be inferred to have that signature.
Language: F#
let sigA a = a+2
let sigB a = printfn "%i" a
let sigC a = a.ToString();;
let sigD = reader.ReadLine()
let sigE (s:string) = s.chars(2)
let sigF 3 : true : 0.5 = "hi";;
For each of the following signatures, create a function that will be inferred to have that...
| Design a TM in a high level language for La fotbZ:x.y>O;239;zz|xy13
Question 8 10 pts Let S = {a,b,c}. Write a grammar that generates the language: L = {(ac)"6n+1w: n > 0, W € 2*, W contains the substring acb}
IF Let x(t) Show that e 20" σ>0, and let (o) be the Fourier transform of x(t) .
Let Y be a random variable with probability density function, pdf, f(y) = 2e-2y, y > 0. Determine f (U), the pdf of U = VY.
5. Let X have exponential pdf λe_AE 0 when x > 0 otherwise with λ = 3. Let Y-LX). Find E(Y) and Var(Y)
Detail Explain please:
6 Impulse Response Let h(t) denote the response of a system for which the input signal is the unit-impulse t 0: he(t) = t [a(t) _ u(t-1)] + 2a(t-2), for t > 0.
4. Let f(x) = 22xe-2x,x>> 0). Assume that we have a random sample of size n from this distribution. Find the maximum likelihood estimator of 2.
Exponential(). That is Y has a density function of the form 7. Let Y Ay f(y) = de"^9,y> 0 where 0. Show that: (a) If a >0 and b > 0, then P(Y > a + b|Y > a) = P(Y > b) (b) E(Y) 1/A
C++:
questions are in fish.h. Write the code in fish.cpp and
main.cpp
#ifndef FISH_H #define FISH_H #include <vector> class Fish { public: // (1 point) // Write code to initialize edible to is_edible, age to 0, size to 1. Fish (bool is_edible); // (1 point) // Print the vital stats (size and age) of the fish. void Print(); // (1 point) // If fish is at least the age of reproduce_age, reproduce with probability // of reproduce_probability. If reproduce, return...
Let sigma = {a, b, c}. Draw the transition graph of a npda that accepts the following language: L = {c(ab)^n a^m c^n: n greaterthanorequalto 1, m greaterthanorequalto 0} Write the sequence of moves done by the npda when the input sequence is w = cabc. Is the string w accepted?