Sure! Here's an example in VHDL:
library ieee;
use ieee.std_logic_1164.all;
entity if_logic_example is
port (
a, b, c: in std_logic;
x, y: out std_logic
);
end if_logic_example;
architecture rtl of if_logic_example is
begin
process(a, b, c)
begin
if a = '1' and b = '0' then
x <= '1';
else
x <= '0';
end if;
if c = '1' or (a = '0' and b = '0') then
y <= '1';
else
y <= '0';
end if;
end process;
end rtl;
This code defines an entity if_logic_example with three input signals a, b, and c, and two output signals x and y. The rtl architecture contains a process that is triggered whenever any of the input signals change.
In the process, there are two if statements that define the behavior of the output signals. The first if statement checks if a is high and b is low, and sets x to high if this is true, or low otherwise. The second if statement checks if c is high or if both a and b are low, and sets y to high if this is true, or low otherwise.